﻿:root {
  --bg-a: #000000;
  --bg-b: #010101;
  --bg-c: #020202;
  --bg-d: #050507;
  --text-main: #f5f5f5;
  --text-soft: #a1a1aa;
  --line: rgba(255, 255, 255, 0.1);
  --panel: rgba(13, 13, 13, 0.78);
  --panel-strong: rgba(18, 18, 18, 0.92);
  --accent: #ffffff;
  --accent-strong: #d4d4da;
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
  --max-width: 1380px;
  --radius: 18px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  background: var(--bg-a);
  color: var(--text-main);
  font-family: "Manrope", sans-serif;
  overflow-x: hidden;
  text-align: center;
}

.bg-aurora {
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(circle at 12% 18%, rgba(84, 120, 186, 0.065), transparent 48%),
    radial-gradient(circle at 84% 12%, rgba(56, 88, 150, 0.05), transparent 46%),
    linear-gradient(135deg, var(--bg-a) 0%, var(--bg-b) 35%, var(--bg-c) 68%, var(--bg-d) 100%);
  background-size: 165% 165%;
  animation: aurora 42s ease-in-out infinite;
}

@keyframes aurora {
  0% {
    background-position: 48% 50%;
  }
  50% {
    background-position: 52% 50%;
  }
  100% {
    background-position: 48% 50%;
  }
}

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

.topbar {
  position: fixed;
  top: 16px;
  left: 50%;
  transform: translateX(-50%);
  width: min(calc(100% - 120px), 840px);
  padding: 7px 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(5, 5, 5, 0.84);
  backdrop-filter: blur(11px);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.42);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 40;
}

.nav-menu {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: auto;
  gap: 22px;
  padding: 0 10px 6px;
}

.nav-link {
  font-size: 0.98rem;
  font-weight: 600;
  color: var(--text-soft);
  padding: 4px 6px 2px;
  transition: color 0.26s ease;
  white-space: nowrap;
}

.nav-link:hover,
.nav-link.selected {
  color: #ffffff;
}

.nav-link-cta {
  padding: 7px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.09);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.nav-indicator {
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  border-radius: 999px;
  background: var(--accent-strong);
  opacity: 0;
  pointer-events: none;
  transition: left 0.38s cubic-bezier(0.2, 0.8, 0.2, 1), width 0.38s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.18s ease, filter 0.2s ease;
}

.nav-indicator::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: inherit;
  filter: blur(4px);
  opacity: 0.42;
}

.nav-indicator.visible {
  opacity: 1;
}

.nav-indicator.moving {
  filter: blur(1.2px);
}

.menu-btn {
  display: none;
  width: 36px;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.menu-btn span {
  display: block;
  height: 2px;
  width: 100%;
  border-radius: 999px;
  background: #e4e4e8;
  margin: 6px 0;
}

main {
  width: min(100%, var(--max-width));
  margin: 0 auto;
  padding: 0 20px 82px;
}

.section {
  scroll-margin-top: 100px;
}

.home-section {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding-top: 108px;
}

.home-content {
  text-align: center;
  width: min(980px, 100%);
  margin: 0 auto;
}

.home-title {
  margin: 0;
  min-height: clamp(68px, 7vw, 102px);
  display: block;
  position: relative;
  overflow: hidden;
  width: 100%;
  max-width: 100%;
  text-align: center;
  font-family: "Syne", sans-serif;
  font-size: clamp(2.2rem, 5.6vw, 4.6rem);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: 0.3px;
  color: #ffffff;
  margin-left: auto;
  margin-right: auto;
}

.home-title-track {
  position: relative;
  display: block;
  width: 100%;
  height: clamp(68px, 7vw, 102px);
}

.home-title-phrase {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  color: #ffffff;
  opacity: 0;
  transform: translateY(-120%);
  transition: transform 1.55s cubic-bezier(0.2, 0.82, 0.24, 1), opacity 1.1s ease;
  will-change: transform, opacity;
}

.home-title-phrase.is-active,
.home-title-phrase.is-entering {
  opacity: 1;
  transform: translateY(0);
}

.home-title-phrase.is-leaving {
  opacity: 0;
  transform: translateY(120%);
}

.home-title-phrase.is-reset {
  transition: none;
  opacity: 0;
  transform: translateY(-120%);
}

.home-title-phrase span {
  color: #1f4fa8;
  margin-left: 0.14em;
}

.subtitle {
  margin: 18px auto 0;
  width: fit-content;
  max-width: 100%;
  color: #9398a1;
  font-size: clamp(1rem, 1.35vw, 1.45rem);
  line-height: 1.48;
  white-space: nowrap;
}

.home-actions {
  margin-top: 34px;
  display: flex;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
}

.cta-btn {
  border-radius: 14px;
  min-width: 230px;
  padding: 17px 36px;
  font-size: 1.08rem;
  font-weight: 700;
  letter-spacing: 0.3px;
  border: 1px solid transparent;
  transition: transform 0.28s ease, box-shadow 0.28s ease, background-color 0.28s ease, border-color 0.28s ease;
}

.cta-btn:hover {
  transform: scale(1.03);
}

.cta-btn.primary {
  background: linear-gradient(135deg, #4e9dff 0%, #2f68cf 100%);
  color: #eef5ff;
  box-shadow: 0 12px 30px rgba(44, 105, 211, 0.42);
}

.cta-btn.primary span {
  margin-left: 8px;
}

.cta-btn.secondary {
  background: rgba(7, 10, 18, 0.66);
  border-color: rgba(255, 255, 255, 0.12);
  color: #eceff5;
}

.cta-btn.secondary:hover {
  background: rgba(12, 17, 28, 0.82);
  border-color: rgba(78, 157, 255, 0.42);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.32);
}

.content-section {
  padding-top: 126px;
}

h2 {
  font-family: "Syne", sans-serif;
  font-size: clamp(2.4rem, 5vw, 4rem);
  letter-spacing: 0.6px;
  margin-bottom: 28px;
}

#long-forms h2,
#short-forms h2 {
  margin-bottom: 44px;
}

.video-grid {
  display: grid;
  gap: 26px;
}

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

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

.video-card {
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--panel);
  box-shadow: var(--shadow);
  transform: translateY(0);
  transition: transform 0.28s ease, border-color 0.28s ease;
}

.video-card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 255, 255, 0.32);
}

.video-card iframe {
  width: 100%;
  border: 0;
  display: block;
  aspect-ratio: 16 / 9;
}

.short-card iframe {
  aspect-ratio: 9 / 16;
  max-height: 600px;
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 30px;
  justify-items: center;
}

.service-card {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(5, 5, 5, 0.84);
  backdrop-filter: blur(11px);
  -webkit-backdrop-filter: blur(11px);
  padding: 24px 30px;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.42);
  text-align: center;
}

.icon-shell {
  width: 100%;
  display: flex;
  justify-content: center;
  margin-bottom: 16px;
  animation: serviceIconFloat 5.2s ease-in-out infinite;
}

.service-card:nth-child(2) .icon-shell {
  animation-delay: 0.8s;
}

.service-card:nth-child(3) .icon-shell {
  animation-delay: 1.6s;
}

.service-icon {
  width: 68px;
  height: 68px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  color: #4c96ff;
  background: linear-gradient(158deg, rgba(3, 7, 14, 0.99) 0%, rgba(5, 10, 20, 0.98) 48%, rgba(2, 5, 10, 0.99) 100%);
  border: 1px solid rgba(6, 10, 18, 0.92);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), inset 0 -10px 18px rgba(0, 0, 0, 0.46), 0 10px 20px rgba(0, 0, 0, 0.36);
  position: relative;
  isolation: isolate;
  overflow: hidden;
  transition: transform 0.36s ease, box-shadow 0.36s ease, border-color 0.36s ease, color 0.36s ease;
}

.service-icon svg {
  width: 33px;
  height: 33px;
  display: block;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
  position: relative;
  z-index: 3;
}

.service-icon::before {
  content: "";
  position: absolute;
  top: -52%;
  left: -165%;
  width: 50%;
  height: 205%;
  border-radius: 14px;
  transform: skewX(-16deg);
  pointer-events: none;
  background: linear-gradient(120deg, rgba(6, 16, 38, 0) 0%, rgba(10, 27, 60, 0.22) 30%, rgba(13, 36, 79, 0.62) 50%, rgba(9, 24, 54, 0.28) 70%, rgba(6, 16, 38, 0) 100%);
  mix-blend-mode: normal;
  filter: blur(26px);
  box-shadow: 0 0 54px rgba(13, 35, 77, 0.62);
  opacity: 0.94;
  z-index: 1;
  animation: serviceIconSweep 6.4s cubic-bezier(0.35, 0.08, 0.2, 0.98) infinite;
}

.service-icon::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0) 42%);
  z-index: 2;
}

.service-card:hover .service-icon {
  transform: translateY(-1px) scale(1.02);
  color: #63a7ff;
  border-color: rgba(8, 14, 24, 0.96);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12), inset 0 -10px 20px rgba(0, 0, 0, 0.5), 0 11px 18px rgba(0, 0, 0, 0.38);
}

@keyframes serviceIconSweep {
  0%,
  68% {
    left: -165%;
  }
  100% {
    left: 175%;
  }
}

@keyframes serviceIconFloat {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-6px);
  }
}

.service-card h3 {
  font-size: 1.32rem;
  margin-bottom: 12px;
}

.service-card p {
  color: var(--text-soft);
  line-height: 1.75;
  margin-bottom: 16px;
}

.service-card ul {
  list-style: none;
  display: grid;
  gap: 10px;
  color: #d6d6db;
  font-weight: 600;
}

.service-card li {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
}

.service-card li::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-strong);
}

.about-card {
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(5, 5, 5, 0.84);
  backdrop-filter: blur(11px);
  -webkit-backdrop-filter: blur(11px);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.42);
  max-width: 980px;
  margin: 0 auto;
  padding: clamp(26px, 4vw, 40px);
  text-align: center;
}

.about-card p {
  color: var(--text-soft);
  line-height: 1.82;
  font-size: 1.08rem;
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
}

.about-card p + p {
  margin-top: 18px;
}

#contact-me {
  margin-top: 120px;
}

.social-grid {
  display: flex;
  justify-content: center;
  gap: 14px;
  flex-wrap: nowrap;
  align-items: center;
  max-width: none;
  margin: 39px auto 0;
}

.social-link {
  --social-color: #ffffff;
  border: 0;
  border-radius: 999px;
  background: transparent;
  min-height: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0;
  color: #f2f2f5;
  transition: transform 0.22s ease, color 0.22s ease;
}

.social-link:hover {
  transform: translateY(-2px);
  color: var(--social-color);
}

.social-link svg {
  width: 64px;
  height: 64px;
  padding: 15px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.32);
  background: rgba(10, 10, 10, 0.88);
  fill: currentColor;
  transition: transform 0.22s ease, border-color 0.22s ease, background-color 0.22s ease, box-shadow 0.22s ease;
}

.social-link:hover svg {
  transform: scale(1.08);
  border-color: currentColor;
  background: rgba(17, 17, 17, 0.98);
  box-shadow: 0 0 0 1px currentColor, 0 0 14px currentColor;
}

.social-link.twitter {
  --social-color: #74cdff;
}

.social-link.discord {
  --social-color: #8e7dff;
}

.social-link.email {
  --social-color: #ffbc73;
}

.social-link.youtube {
  --social-color: #ff5252;
}

.social-link.instagram {
  --social-color: #ff79bf;
}

.footer {
  width: min(100%, var(--max-width));
  margin: 48px auto 26px;
  padding: 0 20px;
  color: #8e8e96;
  font-size: 0.95rem;
  text-align: center;
}

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

@media (max-width: 1240px) {
  .long-grid,
  .short-grid,
  .service-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 980px) {
  .social-grid {
    gap: 10px;
    flex-wrap: wrap;
    max-width: 500px;
  }
}

@media (max-width: 860px) {
  .topbar {
    top: 8px;
    width: min(calc(100% - 24px), 520px);
    padding: 10px 14px;
    justify-content: space-between;
    border-radius: 16px;
  }

  .menu-btn {
    display: block;
  }

  .nav-menu {
    position: absolute;
    right: 14px;
    top: 56px;
    width: min(300px, calc(100vw - 40px));
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: rgba(10, 10, 10, 0.94);
  }

  .nav-menu.open {
    display: flex;
  }

  .nav-link {
    font-size: 0.98rem;
  }

  .nav-indicator {
    display: none;
  }

  .long-grid,
  .short-grid,
  .service-grid {
    grid-template-columns: 1fr;
  }

  .social-grid {
    max-width: 100%;
    gap: 8px;
  }

  .short-card iframe {
    max-height: none;
  }

  .content-section {
    padding-top: 94px;
  }

  #contact-me {
    margin-top: 88px;
  }
}

@media (max-width: 560px) {
  .subtitle {
    white-space: normal;
    width: 100%;
  }

  .home-title-phrase {
    white-space: normal;
  }

  .home-title-phrase span {
    margin-left: 0.12em;
  }

  .cta-btn {
    width: 100%;
  }

  .social-link svg {
    width: 58px;
    height: 58px;
    padding: 13px;
  }
}

