/*
  Footer (snippets/footer.bwt), class tiền tố ft-*.
  Tải sau theme-refresh.css: dùng biến màu --brand-* khai báo trên body ở file đó.
  Class .footer-details giữ nguyên vì defer-scripts.js dùng để gập mở menu trên di động.
*/
.site-footer {
  margin-top: 4rem;
  background: #fff;
  color: var(--color-foreground);
  font-size: 1.5rem;
  line-height: 1.6;
}

.site-footer p {
  margin: 0;
}

.site-footer a {
  transition: color 0.2s ease;
}

/* Dải trên cùng: xanh pha rất nhạt */
.ft-top {
  background: linear-gradient(120deg, #f2f7fe 0%, #e8f0fc 100%);
  border-top: 1px solid #e1eaf8;
  color: var(--color-foreground);
}

.ft-top__inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  padding: 2.4rem 0;
}

@media (min-width: 1024px) {
  .ft-top__inner {
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 4rem;
  }
}

.ft-hotlines {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(22rem, 1fr));
  gap: 1.2rem;
}

.ft-hotline {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  padding: 1.2rem 1.6rem;
  border-radius: 1.2rem;
  background: #fff;
  border: 1px solid #dfe8f6;
  color: var(--color-foreground);
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.ft-hotline:hover {
  border-color: #b9cff2;
  box-shadow: 0 6px 18px rgba(5, 76, 174, 0.08);
  color: var(--color-foreground);
}

.ft-hotline__icon {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 4.4rem;
  height: 4.4rem;
  border-radius: 9999px;
  background: var(--brand-red-50);
  color: var(--brand-red);
  font-size: 2rem;
}

.ft-hotline__text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.ft-hotline__label {
  font-size: 1.3rem;
  color: var(--text-muted);
}

.ft-hotline__number {
  font-size: 1.9rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  line-height: 1.3;
  color: var(--brand-blue);
}

.ft-newsletter .email-subscribe {
  gap: 0.6rem;
}

.ft-newsletter .email-subscribe > p:first-child {
  font-size: 1.7rem;
  font-weight: 600;
  color: #13315c;
}

.ft-newsletter .email-subscribe > p {
  color: var(--text-muted);
}

.ft-newsletter .form-input {
  height: 4.6rem;
  padding: 0 2rem;
  border: 1px solid #dfe8f6;
  color: var(--color-foreground);
}

.ft-newsletter .form-input:focus {
  border-color: var(--brand-blue);
  box-shadow: 0 0 0 3px var(--brand-blue-50);
}

.ft-newsletter .button_subscribe {
  height: 4.6rem;
  padding: 0 2.6rem;
  background: var(--brand-blue);
  font-weight: 500;
}

.ft-newsletter .button_subscribe:hover {
  background: var(--brand-blue-dark);
}

.ft-newsletter .mailchimp-alerts {
  margin-top: 0;
}

/* Nội dung chính */
.ft-main {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.4rem;
  padding: 2.8rem 0 2rem;
}

@media (min-width: 768px) {
  .ft-main {
    grid-template-columns: 1fr 1fr;
    gap: 3.2rem;
    padding: 4rem 0 3.2rem;
  }
}

@media (min-width: 1024px) {
  .ft-main {
    grid-template-columns: 1.5fr 1fr 1fr 1.1fr;
    gap: 4rem;
  }
}

.ft-col--about {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 1.6rem;
}

@media (min-width: 768px) {
  .ft-col--about {
    margin-bottom: 0;
  }
}

.ft-logo img {
  width: auto;
  max-height: 5.2rem;
  object-fit: contain;
}

.ft-company {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--brand-blue);
}

.ft-legal {
  font-size: 1.35rem;
  color: var(--text-muted);
}

.ft-legal strong {
  color: var(--color-foreground);
  font-weight: 600;
}

.ft-contact {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin: 0.4rem 0 0;
  padding: 0;
  list-style: none;
}

.ft-contact__item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  font-size: 1.4rem;
  color: var(--text-muted);
}

.ft-contact__item .icon {
  flex-shrink: 0;
  margin-top: 0.2rem;
  color: var(--brand-red);
  font-size: 1.8rem;
}

.ft-contact__item strong {
  color: var(--color-foreground);
  font-weight: 600;
}

.ft-link-strong {
  font-weight: 600;
  color: var(--brand-blue);
}

.ft-link-strong:hover {
  color: var(--brand-red);
}

.site-footer .ft-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  margin: 0 0 1.6rem;
  padding-bottom: 1rem;
  font-size: 1.4rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #13315c;
  list-style: none;
}

.ft-heading::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 2.4rem;
  height: 2px;
  border-radius: 9999px;
  background: var(--brand-red);
}

.ft-heading__caret {
  display: none;
}

.ft-menu {
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.ft-menu a {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--color-foreground);
  transition:
    color 0.2s ease,
    transform 0.2s ease;
}

.ft-menu a::before {
  content: '';
  width: 0.6rem;
  height: 0.6rem;
  flex-shrink: 0;
  border-top: 2px solid currentColor;
  border-right: 2px solid currentColor;
  transform: rotate(45deg);
  opacity: 0.35;
}

.ft-menu a:hover {
  color: var(--brand-blue);
  transform: translateX(2px);
}

.ft-menu a:hover::before {
  opacity: 1;
  color: var(--brand-red);
}

/* Cột phải: mạng xã hội, thanh toán, Bộ Công Thương */
.ft-block + .ft-block {
  margin-top: 2.8rem;
}

.ft-social > div {
  flex-wrap: wrap;
  gap: 1rem;
}

.ft-social > div > div {
  width: 4.2rem;
  height: 4.2rem;
  border: 1px solid var(--surface-border);
  border-radius: 9999px;
  background: #fff;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    transform 0.2s ease;
}

.ft-social > div > div:hover {
  background: #fff;
  border-color: var(--brand-blue-100);
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-2px);
}

.ft-social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.ft-payment {
  display: inline-block;
  padding: 0.8rem 1.2rem;
  border: 1px solid var(--surface-border);
  border-radius: 1rem;
}

.ft-payment img {
  display: block;
  max-width: 100%;
  height: auto;
}

.ft-bct img {
  display: block;
  width: 12.8rem;
  height: auto;
}

/* Dòng bản quyền */
.ft-bottom {
  border-top: 1px solid var(--surface-border);
  background: #f7f9fc;
}

.ft-bottom__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.4rem 1rem;
  padding: 1.4rem 0;
  font-size: 1.35rem;
  color: var(--text-muted);
  text-align: center;
}

.ft-bottom__inner a {
  font-weight: 600;
  color: var(--color-foreground);
}

.ft-bottom__inner a:hover {
  color: var(--brand-blue);
}

.ft-bottom__sep {
  opacity: 0.4;
}

/* Di động: 2 cột menu thành dạng gập mở */
@media (max-width: 767px) {
  .site-footer {
    margin-top: 2.4rem;
  }

  .ft-col .footer-details {
    border-top: 1px solid var(--surface-border);
  }

  .ft-col .footer-details .ft-heading {
    margin-bottom: 0;
    padding: 1.4rem 0;
    cursor: pointer;
  }

  .ft-col .footer-details .ft-heading::after {
    content: none;
  }

  .ft-col .footer-details .ft-heading__caret {
    display: inline-block;
    transition: transform 0.2s ease;
  }

  .ft-col .footer-details .ft-menu {
    padding-bottom: 1.6rem;
  }

  .ft-col:last-child {
    padding-top: 2rem;
    border-top: 1px solid var(--surface-border);
  }
}
