/* Site footer, three rows:
   1) logos | Contact Us | Address | Follow Us
   2) the "TCI's health and safety programme" container
   3) copyright bar
   Light theme and yellow accent as before; responsive from 320px up. */

.site-footer {
  background: #f5f5f5;
  color: var(--dark);
  border-top: 2px solid #ddd;
  font-family: var(--font);
}

.site-footer .container {
  width: min(100%, var(--max-width));
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- row 1: logos + contact columns ---------- */
.site-footer .footer-grid {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) minmax(0, 1.2fr) minmax(0, 0.9fr);
  gap: 48px;
  align-items: start;
  padding: 40px 0 28px;
}

.site-footer .footer-col {
  min-width: 0;
}

.site-footer .footer-logos {
  display: flex;
  align-items: center;
  gap: 16px;
}

.site-footer .footer-logos img {
  display: block;
  width: 108px;
  height: auto;
}

.site-footer .footer-logos .footer-logo-junior {
  width: 88px;
}

/* column headings with a small yellow accent */
.site-footer .footer-col h2 {
  position: relative;
  margin: 0 0 18px;
  padding-bottom: 10px;
  font-family: var(--font);
  font-size: 16px;
  font-weight: 600;
  line-height: 1.35;
  color: var(--dark);
}

.site-footer .footer-col h2::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 28px;
  height: 3px;
  border-radius: 2px;
  background: var(--primary);
}

/* contact + address rows: icon in a small white circle */
.site-footer .footer-contact {
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-footer .footer-contact li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin: 0 0 12px;
}

.site-footer .footer-contact li:last-child {
  margin-bottom: 0;
}

.site-footer .footer-contact svg {
  flex: none;
  box-sizing: content-box;
  width: 14px;
  height: 14px;
  padding: 8px;
  border: 1px solid #e8e8e8;
  border-radius: 50%;
  background: #fff;
  fill: var(--primary);
}

.site-footer .footer-contact a,
.site-footer .footer-contact span {
  padding-top: 5px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--dark);
  text-decoration: none;
  overflow-wrap: anywhere;
}

.site-footer .footer-contact a {
  transition: color 0.2s ease;
}

.site-footer .footer-contact a:hover,
.site-footer .footer-contact a:focus-visible {
  color: #b98200;
}

/* social icons: uniform circles, brand-coloured glyphs */
.site-footer .social-icons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.site-footer .social-icons a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 38px;
  height: 38px;
  border: 1px solid #e2e2e2;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.site-footer .social-icons svg {
  display: block;
  width: 17px;
  height: 17px;
  transition: transform 0.25s ease;
}

.site-footer .social-icons .social-facebook svg { fill: #1877f2; }
.site-footer .social-icons .social-instagram svg { fill: url(#footer-instagram-gradient); }
.site-footer .social-icons .social-youtube svg { fill: #ff0000; }
.site-footer .social-icons .social-linkedin svg { fill: #0a66c2; }

.site-footer .social-icons a:hover,
.site-footer .social-icons a:focus-visible {
  transform: translateY(-3px);
  border-color: var(--primary);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.14);
}

.site-footer .social-icons a:hover svg,
.site-footer .social-icons a:focus-visible svg {
  transform: scale(1.1);
}

.site-footer a:focus-visible {
  outline: 2px solid var(--dark);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  .site-footer .social-icons a,
  .site-footer .social-icons svg { transition: none; }
  .site-footer .social-icons a:hover,
  .site-footer .social-icons a:focus-visible,
  .site-footer .social-icons a:hover svg,
  .site-footer .social-icons a:focus-visible svg { transform: none; }
}

/* ---------- row 2: the programme container ---------- */
.site-footer .footer-about {
  display: grid;
  /* heading takes only the width it needs; the description gets the rest, so the two sit close together */
  grid-template-columns: max-content minmax(0, 1fr);
  align-items: center;
  gap: 12px 0;
  margin: 0 0 24px;
  padding: 22px 28px;
  border: 1px solid #ebebeb;
  border-left: 4px solid var(--primary);
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
}

.site-footer .footer-about h2 {
  margin: 0;
  font-family: var(--font);
  font-size: 18px;
  font-weight: 600;
  line-height: 1.35;
  color: var(--dark);
  padding-right: 28px;
}

.site-footer .footer-about p {
  margin: 0;
  padding-left: 28px;
  border-left: 1px solid #ececec;
  font-size: 14px;
  line-height: 1.7;
  color: #4a4a4a;
  text-align: left;
}

/* narrower laptops/tablets: tighten the spacing and let the heading wrap if it has to */
@media (max-width: 1024px) {
  .site-footer .footer-about {
    grid-template-columns: minmax(0, max-content) minmax(0, 1fr);
    padding: 20px 22px;
  }

  .site-footer .footer-about h2 {
    padding-right: 20px;
  }

  .site-footer .footer-about p {
    padding-left: 20px;
  }
}

/* ---------- row 3: copyright ---------- */
.site-footer .footer-divider {
  padding: 14px 0;
  border-top: 1px solid #e0e0e0;
  text-align: center;
}

.site-footer .footer-divider p {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  color: #555;
}

/* ---------- tablets: logos on their own line, then the three columns ---------- */
@media (max-width: 1024px) {
  .site-footer .footer-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 26px 32px;
    padding: 32px 0 26px;
  }

  .site-footer .footer-logo {
    grid-column: 1 / -1;
  }
}

/* ---------- phones: one tight column ---------- */
@media (max-width: 767px) {
  .site-footer .footer-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
    padding: 26px 0 20px;
  }

  .site-footer .footer-logo {
    padding-bottom: 20px;
  }

  .site-footer .footer-col + .footer-col {
    padding: 18px 0;
    border-top: 1px solid #e3e3e3;
  }

  .site-footer .footer-col + .footer-col:last-child {
    padding-bottom: 0;
  }

  .site-footer .footer-col h2 {
    margin-bottom: 12px;
  }

  .site-footer .footer-about {
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
    margin-bottom: 20px;
    padding: 18px 18px 18px 20px;
  }

  .site-footer .footer-about h2 {
    padding-right: 0;
    font-size: 17px;
  }

  .site-footer .footer-about p {
    padding-left: 0;
    border-left: 0;
  }

  .site-footer .footer-divider {
    padding: 12px 0;
  }
}
