/**
 * Footer component.
 */
.footer {
  margin-top: auto;
  padding: var(--space-xl) 0;
  background-color: #111827;
  color: #e5e7eb;
}

.footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-xl);
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-padding);
}

.footer__left {
  flex: 1 1 18rem;
}

.footer__ready-title {
  margin: 0 0 var(--space-sm);
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: var(--font-weight-semibold);
  color: #f9fafb;
}

.footer__ready-subtitle {
  margin: 0 0 var(--space-md);
  font-size: var(--font-size-base);
  color: #d1d5db;
}

.footer__contact-btn {
  display: inline-block;
  padding: var(--space-sm) var(--space-md);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-medium);
  color: #fff;
  background-color: var(--color-primary);
  border-radius: var(--radius-md, 0.375rem);
  text-decoration: none;
  transition: background-color 0.2s, color 0.2s;
}

.footer__contact-btn:hover {
  background-color: var(--color-primary-dark);
  color: #fff;
}

.footer__right {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xl);
}

.footer__block {
  flex: 0 1 auto;
}

.footer__col {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.footer__block--lang {
  margin-top: 0;
}

.footer__block-title {
  margin: 0 0 var(--space-sm);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
  color: #f9fafb;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.footer__line {
  margin: 0 0 var(--space-xs);
  font-size: var(--font-size-sm);
  color: #d1d5db;
}

.footer__line:last-child {
  margin-bottom: 0;
}

.footer__line a {
  color: #d1d5db;
  text-decoration: none;
}

.footer__line a:hover {
  color: #f9fafb;
  text-decoration: underline;
}

.footer__langs {
  margin: 0;
  display: flex;
  gap: var(--space-sm);
  font-size: var(--font-size-sm);
}

.footer__lang {
  color: #d1d5db;
  text-decoration: none;
}

.footer__lang:hover {
  color: #f9fafb;
}

.footer__lang--active {
  color: #f9fafb;
  font-weight: var(--font-weight-semibold);
}

/* Bottom bar: divider line, brand left, legal links right */
.footer__bottom {
  border-top: 1px solid #374151;
  margin-top: var(--space-xl);
  padding-top: var(--space-md);
}

.footer__bottom-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-padding);
}

.footer__brand {
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-semibold);
  color: #f9fafb;
  text-decoration: none;
}

.footer__brand:hover {
  color: #fff;
}

.footer__legal {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-sm);
}

.footer__legal a {
  font-size: var(--font-size-sm);
  color: #d1d5db;
  text-decoration: none;
}

.footer__legal a:hover {
  color: #f9fafb;
}

.footer__legal a:not(:last-child)::after {
  content: "·";
  margin-left: var(--space-sm);
  color: #6b7280;
  font-weight: bold;
}

/* Tablet */
@media (max-width: 64rem) {
  .footer {
    padding: var(--space-2xl) 0 var(--space-xl);
  }

  .footer__inner {
    gap: var(--space-2xl);
  }

  .footer__right {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-xl);
    width: 100%;
  }

  .footer__col {
    gap: var(--space-xl);
  }
}

/* Mobile */
@media (max-width: 48rem) {
  .footer {
    padding: var(--space-xl) 0 var(--space-lg);
  }

  .footer__inner {
    flex-direction: column;
    align-items: stretch;
    gap: var(--space-xl);
  }

  .footer__left {
    flex: none;
    padding-bottom: var(--space-lg);
    border-bottom: 1px solid #374151;
  }

  .footer__ready-title {
    font-size: 1.25rem;
  }

  .footer__ready-subtitle {
    font-size: var(--font-size-sm);
    margin-bottom: var(--space-lg);
  }

  .footer__contact-btn {
    display: block;
    text-align: center;
    padding: var(--space-md) var(--space-lg);
    font-size: var(--font-size-base);
  }

  .footer__right {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
    width: 100%;
  }

  .footer__block {
    flex: none;
  }

  .footer__block-title {
    margin-bottom: var(--space-sm);
  }

  .footer__line {
    margin-bottom: var(--space-sm);
  }

  .footer__bottom {
    margin-top: var(--space-lg);
    padding-top: var(--space-lg);
  }

  .footer__bottom-inner {
    flex-direction: column;
    align-items: stretch;
    gap: var(--space-md);
  }

  .footer__legal {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-sm);
  }

  .footer__legal a:not(:last-child)::after {
    display: none;
  }
}
