/* Footer — solid ink + Samarkand skyline accent */

.site-footer {
  --foot-ink: #040e30;
  position: relative;
  overflow: hidden;
  color: var(--foot-fg);
  padding: clamp(10px, 1.6vw, 14px) 0 calc(8px + var(--safe-b));
  margin: 0;
  background-color: var(--foot-ink);
  background-image: none;
  isolation: isolate;
}

.site-footer::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.07;
  background-image: url("../img/paper-grain-soft.webp");
  background-size: 256px 256px;
  background-repeat: repeat;
  mix-blend-mode: soft-light;
}

.site-footer::after {
  content: none;
}

.site-footer__skyline {
  position: absolute;
  z-index: 0;
  right: 0;
  bottom: 0;
  top: auto;
  height: 100%;
  width: auto;
  max-width: min(58vw, 720px);
  aspect-ratio: 2 / 1;
  display: flex;
  justify-content: flex-end;
  align-items: flex-end;
  pointer-events: none;
  opacity: 1;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 32%, #000 100%);
  mask-image: linear-gradient(90deg, transparent 0%, #000 32%, #000 100%);
}

.site-footer__skyline-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: right bottom;
}

.site-footer > .container {
  position: relative;
  z-index: 1;
}

.site-footer__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(10px, 1.8vw, 16px);
  align-items: start;
}

.site-footer__col--brand {
  min-width: 0;
}

.site-footer__brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  line-height: 0;
  margin-bottom: 6px;
  color: var(--foot-fg);
}

.site-footer__brand .logo__img,
.logo__img--footer {
  height: 32px;
  width: auto;
  max-width: min(180px, 56vw);
  object-fit: contain;
  /* Dark wordmark → light on footer */
  filter: brightness(0) invert(1);
}

.site-footer__text {
  font-size: 0.875rem;
  line-height: 1.35;
  color: var(--foot-mut);
  margin: 0 0 18px;
  max-width: 36ch;
}

.site-footer__credit {
  margin: 4px 0 0;
  font-size: 0.9375rem;
  line-height: 1.35;
  color: var(--c-green);
}

.site-footer__credit-link,
.site-footer__credit-name {
  color: var(--c-green);
  font-weight: 600;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
}

.site-footer__credit-link {
  transition:
    color 0.25s ease,
    text-shadow 0.25s ease;
}

.site-footer__credit-link:hover,
.site-footer__credit-link:focus-visible {
  color: #3dd68c;
  text-shadow:
    0 0 10px rgba(31, 169, 104, 0.45),
    0 0 22px rgba(61, 214, 140, 0.28);
  outline: none;
}

.site-footer__copy {
  margin: 14px 0 0;
  font-size: 0.9375rem;
  line-height: 1.35;
  color: rgba(244, 247, 255, 0.72);
}

.site-footer__label {
  font-weight: 700;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--foot-mut);
  margin-bottom: 6px;
}

.site-footer__col--menu {
  padding: 10px 12px 8px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.site-footer__col--menu .site-footer__label {
  color: rgba(255, 255, 255, 0.72);
  margin-bottom: 6px;
}

.site-footer__nav,
.site-footer__contacts {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.site-footer__col--menu .site-footer__link {
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.3;
  padding: 6px 10px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid transparent;
  -webkit-tap-highlight-color: transparent;
  transition:
    color 0.2s ease,
    background 0.2s ease,
    border-color 0.2s ease;
}

.site-footer__col--menu .site-footer__link:hover,
.site-footer__col--menu .site-footer__link.is-active {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 122, 69, 0.35);
}

.site-footer__link,
.site-footer__contact {
  font-size: 0.9375rem;
  line-height: 1.25;
  color: var(--foot-fg);
  transition: color 0.2s ease;
}

.site-footer__link[data-tone="coral"]:hover,
.site-footer__link[data-tone="coral"].is-active {
  color: var(--c-coral);
}

.site-footer__link[data-tone="green"]:hover,
.site-footer__link[data-tone="green"].is-active {
  color: var(--c-green);
}

.site-footer__link[data-tone="blue"]:hover,
.site-footer__link[data-tone="blue"].is-active {
  color: var(--c-blue);
}

.site-footer__link[data-tone="purple"]:hover,
.site-footer__link[data-tone="purple"].is-active {
  color: var(--c-purple);
}

.site-footer__contact:hover {
  color: var(--c-coral);
}

.site-footer__contact--static {
  color: var(--foot-mut);
  line-height: 1.3;
  font-size: 0.875rem;
}

.site-footer__legal {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-top: 8px;
  padding-top: 0;
}

.site-footer__legal-link {
  font-size: 0.8125rem;
  line-height: 1.3;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.38);
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
  transition: color 0.25s ease;
}

.site-footer__legal-link:hover,
.site-footer__legal-link:focus-visible,
.site-footer__legal-link.is-active {
  color: rgba(244, 247, 255, 0.85);
  outline: none;
}

@media (max-width: 959px) {
  .site-footer {
    padding: clamp(10px, 1.6vw, 14px) 0 calc(8px + var(--safe-b));
  }

  .site-footer__skyline {
    width: min(96vw, 520px);
    max-width: min(96vw, 520px);
    height: auto;
    min-height: clamp(120px, 32vw, 180px);
    aspect-ratio: 2 / 1;
  }

  .site-footer__grid {
    gap: 10px;
  }

  .site-footer__text {
    max-width: none;
    margin-bottom: 8px;
  }

  /* Mobile: page nav is in the burger; keep legal links visible */
  .site-footer__col--menu {
    display: none;
  }

  .site-footer__copy {
    margin-top: 4px;
    font-size: 0.75rem;
  }
}
