body.member-footer-page {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

body > .site-footer {
  margin-top: auto;
  padding: clamp(28px, 4vw, 48px) 0 16px;
  background: #001643;
  border-top: 1px solid #173464;
  color: #c6d7f5;
  font: 500 14px/1.5 system-ui, "Noto Sans Thai", sans-serif;
}

.site-footer > dodive-site-footer {
  display: grid;
  grid-template-columns: minmax(190px, 1.5fr) repeat(3, minmax(114px, 1fr)) auto;
  grid-template-areas: "brand explore member account language" "bottom bottom bottom bottom bottom";
  align-items: start;
  gap: 22px clamp(14px, 3vw, 48px);
  width: min(var(--site-header-width), 100% - 2 * var(--site-header-gutter));
  margin-inline: auto;
}

html[lang="en"] .site-footer span[lang="th"],
html[lang="th"] .site-footer span[lang="en"],
html:not(.show-course) .site-footer [data-footer-feature="course"],
html:not(.show-trip) .site-footer [data-footer-feature="trip"] { display: none; }

.site-footer-brand { grid-area: brand; }
.site-footer-explore { grid-area: explore; }
.site-footer-member { grid-area: member; }
.site-footer-account { grid-area: account; }

.site-footer .brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #fff;
  white-space: nowrap;
}
.site-footer .brand img {
  width: 44px;
  height: 44px;
  object-fit: contain;
}
.site-footer .brand > span {
  font: 800 24px/1.12 system-ui, "Noto Sans Thai", sans-serif;
  letter-spacing: -.04em;
}
.site-footer .brand small {
  display: block;
  margin-top: 2px;
  color: #b5cdf4;
  font: 500 10px/1.4 system-ui, "Noto Sans Thai", sans-serif;
  letter-spacing: 0;
}
.site-footer-brand details { margin-top: 10px; }
.site-footer-brand summary { width: fit-content; cursor: pointer; }
.site-footer-brand p {
  margin: 7px 0 0;
  max-width: 29ch;
  color: #b5cdf4;
  font: inherit;
}

.site-footer h2 {
  margin: 0 0 7px;
  color: #fff;
  font: 750 .96rem/1.35 system-ui, "Noto Sans Thai", sans-serif;
}
.site-footer a { text-decoration: none; }
.site-footer nav a {
  display: block;
  width: fit-content;
  padding-block: 5px;
  color: inherit;
  overflow-wrap: anywhere;
}
.site-footer summary:hover,
.site-footer nav a:hover,
.site-footer nav a[aria-current="page"] {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.site-footer :is(a, summary, button):focus-visible { outline: 2px solid #a5c8ff; outline-offset: 3px; }

.site-footer-language {
  grid-area: language;
  justify-self: end;
  display: flex;
  gap: 2px;
  padding: 3px;
  border: 1px solid #ffffff40;
  border-radius: 24px;
}
.site-footer-language button {
  width: 30px;
  height: 27px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #c4d6f8;
  font: 600 11px/1 system-ui, sans-serif;
  cursor: pointer;
}
.site-footer-language [aria-pressed="true"] { background: #ffffff1a; color: #fff; }
.site-footer-bottom {
  grid-area: bottom;
  padding-top: 13px;
  border-top: 1px solid #ffffff26;
  color: #a6bdde;
  font-size: 12px;
}

@media (max-width: 850px) {
  .site-footer > dodive-site-footer {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-template-areas: "brand brand language" "explore member account" "bottom bottom bottom";
  }
}
@media (max-width: 540px) {
  .site-footer > dodive-site-footer {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-areas: "brand language" "explore member" "account account" "bottom bottom";
    gap: 18px 12px;
  }
  .site-footer nav a { padding-block: 7px; }
}
