/* ==========================================================================
   Master's Touch - Site footer (scoped component)
   Replaces the legacy `footer.style-1` markup. Every selector is prefixed
   .mt-foot* so it never touches legacy footer rules still present in
   styles.css.
   ========================================================================== */

.mt-foot {
  --mt-foot-accent: #e90029;
  --mt-foot-line: rgba(255, 255, 255, .12);
  --mt-foot-muted: rgba(255, 255, 255, .66);
  --mt-foot-font: var(--heading-font-family, "Oxanium"), sans-serif;
  --mt-foot-body: var(--body-font-family, "Sarabun"), sans-serif;
  position: relative;
  background: #050505;
  color: #fff;
  border-top: 1px solid var(--mt-foot-line);
}

/* thin red signature line along the top edge */
.mt-foot::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 0;
  width: min(220px, 40%);
  height: 2px;
  background: var(--mt-foot-accent);
}

.mt-foot__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, .8fr) minmax(0, .8fr) minmax(0, 1.4fr);
  gap: 48px;
  align-items: start;
  padding: 64px 0 48px;
}

/* ---------- brand column ---------- */
.mt-foot__logo {
  display: flex;
  align-items: center;
  height: 44px;
  margin-bottom: 20px;
}

.mt-foot__logo img {
  display: block;
  width: auto;
  height: 44px;
}

.mt-foot__about {
  max-width: 40ch;
  margin: 0 0 24px;
  font-family: var(--mt-foot-body);
  font-size: 15px;
  line-height: 1.7;
  color: var(--mt-foot-muted);
}

.mt-foot__socials {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.mt-foot__social {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  color: #fff;
  border: 1px solid var(--mt-foot-line);
  border-radius: 2px;
  transition: background-color .3s ease, border-color .3s ease, color .3s ease;
}

.mt-foot__social svg {
  display: block;
  width: 18px;
  height: 18px;
}

.mt-foot__social:hover,
.mt-foot__social:focus-visible {
  color: #fff;
  background: var(--mt-foot-accent);
  border-color: var(--mt-foot-accent);
}

.mt-foot__social:focus-visible,
.mt-foot__links a:focus-visible,
.mt-foot__contact a:focus-visible,
.mt-foot__logo:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
}

/* ---------- link columns ---------- */
.mt-foot__title {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 44px;
  margin: 0 0 20px;
  font-family: var(--mt-foot-font);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: #fff;
}

.mt-foot__title::before {
  content: "";
  width: 20px;
  height: 2px;
  background: var(--mt-foot-accent);
}

.mt-foot__links,
.mt-foot__contact {
  margin: 0;
  padding: 0;
  list-style: none;
}

.mt-foot__links li {
  line-height: 1.4;
  margin: 0 0 12px;
  padding: 0;
}

.mt-foot__links a {
  position: relative;
  display: block;
  width: fit-content;
  padding-bottom: 2px;
  font-family: var(--mt-foot-body);
  font-size: 15px;
  line-height: 1.4;
  color: var(--mt-foot-muted);
  text-decoration: none;
  transition: color .25s ease;
}

.mt-foot__links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background: var(--mt-foot-accent);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform .35s cubic-bezier(.2, .7, .2, 1);
}

.mt-foot__links a:hover,
.mt-foot__links a:focus-visible {
  color: #fff;
  text-decoration: none;
}

.mt-foot__links a:hover::after,
.mt-foot__links a:focus-visible::after {
  transform: scaleX(1);
}

/* ---------- contact column ---------- */
.mt-foot__contact li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin: 0 0 16px;
  padding: 0;
  font-family: var(--mt-foot-body);
  font-size: 15px;
  line-height: 1.5;
  color: var(--mt-foot-muted);
}

.mt-foot__contact li:last-child {
  margin-bottom: 0;
}

.mt-foot__contact svg {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  margin-top: 3px;
  color: var(--mt-foot-accent);
}

.mt-foot__contact a {
  color: #fff;
  text-decoration: none;
  overflow-wrap: anywhere;
  transition: color .25s ease;
}

.mt-foot__contact a:hover,
.mt-foot__contact a:focus-visible {
  color: var(--mt-foot-accent);
  text-decoration: none;
}

/* ---------- bottom bar ---------- */
.mt-foot__bar {
  padding: 22px 0 24px;
  border-top: 1px solid var(--mt-foot-line);
}

.mt-foot__bar p {
  margin: 0;
  font-family: var(--mt-foot-body);
  font-size: 14px;
  color: rgba(255, 255, 255, .5);
}

/* ---------- responsive ---------- */
@media (max-width: 1199.98px) {
  .mt-foot__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 40px 32px;
    padding: 52px 0 40px;
  }

  .mt-foot__brand {
    grid-column: 1 / -1;
  }

  .mt-foot__about {
    max-width: 60ch;
  }

  .mt-foot__col--contact {
    grid-column: auto;
  }
}

@media (max-width: 767.98px) {
  .mt-foot__title {
    height: auto;
    margin-bottom: 18px;
  }

  .mt-foot__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 32px 24px;
    padding: 44px 0 36px;
  }

  .mt-foot__col--contact {
    grid-column: 1 / -1;
  }

  .mt-foot__bar {
    padding: 18px 0 22px;
  }
}

@media (max-width: 380px) {
  .mt-foot__grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (prefers-reduced-motion: reduce) {

  .mt-foot__social,
  .mt-foot__links a,
  .mt-foot__links a::after,
  .mt-foot__contact a {
    transition: none;
  }
}
