.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 100;
  border-bottom: 0;
  background: transparent;
  backdrop-filter: none;
  transition: background 0.35s ease, border-color 0.35s ease;
}

.site-header.is-scrolled {
  border-bottom: 1px solid rgba(236, 199, 116, 0.13);
  background: rgba(7, 6, 4, 0.78);
  backdrop-filter: blur(22px) saturate(135%);
}

.site-header .nav {
  min-height: 88px;
  gap: 28px;
}

.site-header .nav-links {
  display: flex;
  align-items: center;
  gap: 30px;
}

.site-header .nav-links > a:not(.button) {
  position: relative;
  color: #c9c1b3;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.site-header .nav-links > a:not(.button)::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: -9px;
  height: 1px;
  background: var(--gold-light);
  transition: right 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

.site-header .nav-links > a:not(.button):hover {
  color: var(--paper);
}

.site-header .nav-links > a:not(.button):hover::after {
  right: 0;
}

.menu-button {
  display: none;
  position: relative;
  z-index: 3;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--paper);
  background: rgba(255, 255, 255, 0.03);
  cursor: pointer;
}

.menu-button span {
  position: absolute;
  left: 13px;
  width: 18px;
  height: 1px;
  background: currentColor;
  transition: transform 0.25s ease, top 0.25s ease;
}

.menu-button span:first-child { top: 18px; }
.menu-button span:last-child { top: 27px; }
.menu-button[aria-expanded="true"] span:first-child {
  top: 22px;
  transform: rotate(45deg);
}
.menu-button[aria-expanded="true"] span:last-child {
  top: 22px;
  transform: rotate(-45deg);
}

.site-footer {
  padding: 74px 0 32px;
  border-top: 1px solid var(--line);
  background: transparent;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.55fr 0.65fr 0.65fr 0.95fr;
  gap: 54px;
  margin-bottom: 60px;
}

.footer-brand img {
  width: 150px;
  height: auto;
  margin-bottom: 20px;
  filter: grayscale(1) brightness(3.4);
  opacity: 0.93;
}

.footer-brand p {
  max-width: 420px;
  margin-bottom: 0;
  color: #938b7f;
  font-size: 0.8rem;
}

.footer-brand .linkedin-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-top: 24px;
  padding: 13px 20px;
  border: 1px solid rgba(245, 217, 143, 0.34);
  border-radius: 999px;
  color: var(--paper);
  font-size: 0.84rem;
  font-weight: 600;
}

.footer-brand .linkedin-link:hover {
  color: var(--gold-light);
  border-color: var(--gold);
  background: rgba(245, 217, 143, 0.07);
}

.footer-brand .linkedin-link img {
  width: 32px;
  height: 32px;
  margin: 0;
  filter: none;
  opacity: 1;
}

.footer-col h4 {
  margin: 0 0 20px;
  color: var(--paper);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.footer-col a,
.footer-col span {
  display: block;
  width: fit-content;
  margin: 11px 0;
  color: #958d81;
  font-size: 0.78rem;
}

.footer-col a:hover { color: var(--gold-light); }

.footer-bottom {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 30px;
  padding-top: 26px;
  border-top: 1px solid var(--line);
  color: #766f65;
  font-size: 0.67rem;
}

.footer-bottom p {
  max-width: 760px;
  margin-bottom: 0;
  color: inherit;
}

.back-top {
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--gold-light);
  background: rgba(255, 255, 255, 0.018);
}

@media (max-width: 1120px) {
  .footer-grid {
    grid-template-columns: 1.4fr 0.7fr 0.7fr;
  }
  .footer-col:last-child { grid-column: 1 / -1; }
}

@media (max-width: 900px) {
  .menu-button { display: block; }
  .site-header .nav-links {
    position: fixed;
    top: 0;
    right: 0;
    z-index: 2;
    width: min(390px, 88vw);
    height: 100dvh;
    padding: 118px 32px 40px;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    border-left: 1px solid var(--line);
    background: rgba(8, 7, 5, 0.97);
    backdrop-filter: blur(24px);
    transform: translateX(104%);
    visibility: hidden;
    pointer-events: none;
    transition: transform 0.48s cubic-bezier(0.22, 1, 0.36, 1), visibility 0s linear 0.48s;
  }
  .site-header .nav-links.is-open {
    transform: translateX(0);
    visibility: visible;
    pointer-events: auto;
    transition-delay: 0s;
  }
  .site-header .nav-links > a:not(.button) {
    display: block;
    padding: 14px 0;
    font-size: 1rem;
  }
  .site-header .nav-links .button {
    margin-top: 14px;
    min-height: 54px;
  }
  .footer-grid { grid-template-columns: 1.35fr 0.65fr 0.65fr; }
}

@media (max-width: 650px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 36px;
  }
  .footer-brand { grid-column: 1 / -1; }
  .footer-col:last-child { grid-column: 1 / -1; }
  .footer-bottom { flex-direction: column; }
}
