/* ScaleSiam — the guardian site footer, shared by every page that shows it.
   Self-contained: it brings its own tokens, type and button styles so
   it renders the same whatever the host page's stylesheet does.
   The guardian IS the footer: one surface, navigation on the left. */
.site-footer {
  --footer-ink: #172238;
  --footer-ink-soft: #626b79;
  --footer-paper: #fafaf7;
  --footer-accent: #475bbe;
  --footer-max: 1280px;
  --footer-gutter: clamp(24px, 5vw, 72px);
  --footer-ease: cubic-bezier(0.23, 1, 0.32, 1);
  position: relative;
  isolation: isolate;
  overflow: clip;
  padding: 0;
  border: 0;
  background:
    radial-gradient(ellipse at 88% 90%, #e9eaf270 0%, transparent 54%),
    var(--footer-paper);
  color: var(--footer-ink);
  font-family: Anuphan, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  letter-spacing: -0.002em;
}
.site-footer a {
  color: inherit;
}
.site-footer .btn,
.site-footer .wordmark {
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
}

.site-footer .guardian-footer-inner {
  position: relative;
  z-index: 1;
  max-width: calc(var(--footer-max) + 2 * var(--footer-gutter));
  margin: 0 auto;
  padding: 64px var(--footer-gutter) 30px;
  min-height: 795px;
}
.site-footer .guardian-footer-content {
  width: 59%;
  max-width: 710px;
}

/* Brand mark */
.site-footer .wordmark,
html[lang="th"] .site-footer .wordmark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--footer-ink);
  font-family: Syne, Anuphan, sans-serif;
  font-weight: 750;
  font-size: 27px;
  letter-spacing: -1.25px;
  line-height: 1;
  white-space: nowrap;
  text-decoration: none;
  transition: opacity 160ms var(--footer-ease);
}
.site-footer .brand-symbol {
  flex: none;
  width: 30px;
  height: 30px;
  color: #5665ba;
}
.site-footer .brand-dot {
  margin: 0;
  color: #6b79c0;
}
.site-footer .guardian-footer-tagline {
  margin: 18px 0 35px;
  color: var(--footer-ink-soft);
  font-size: 13px;
  line-height: 1.6;
}

/* Navigation */
.site-footer .guardian-footer-links {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
  max-width: 480px;
}
.site-footer .footer-link-column {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.site-footer .footer-link-column h2,
html[lang="th"] .site-footer .footer-link-column h2 {
  margin: 0 0 13px;
  padding: 0;
  font: 600 11px/1.5 Anuphan, sans-serif;
  letter-spacing: 0.07em;
  color: #8b91a0;
  text-transform: uppercase;
}
.site-footer .footer-link-column a {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  font-size: 14px;
  color: var(--footer-ink);
  text-decoration: none;
  transition: color 160ms ease;
}

/* Invitation */
.site-footer .footer-invitation {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px 22px;
  margin-top: 35px;
}
.site-footer .footer-invitation h2,
html[lang="th"] .site-footer .footer-invitation h2 {
  margin: 0;
  padding: 0;
  color: var(--footer-ink);
  font-family: Anuphan, sans-serif;
  font-size: 18px;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: -0.025em;
}
.site-footer .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  min-height: 44px;
  padding: 10px 17px;
  border: 0;
  border-radius: 11px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  text-decoration: none;
  cursor: pointer;
  transition:
    transform 180ms var(--footer-ease),
    box-shadow 180ms var(--footer-ease),
    background-color 180ms var(--footer-ease);
}
.site-footer .btn-dark {
  background: linear-gradient(180deg, #34435a, #1b273c);
  color: var(--footer-paper);
  box-shadow:
    inset 0 1px 0 #ffffff35,
    0 2px 3px #17223820,
    0 0 0 1px #182338;
}
.site-footer .btn-dark::after {
  content: "↗";
  font-size: 18px;
  line-height: 1;
}
.site-footer .btn:active {
  transform: scale(0.97);
}
.site-footer .btn:focus-visible {
  border-radius: 999px;
}
html[lang="th"] .site-footer .btn {
  height: auto;
  line-height: 1.35;
  text-align: center;
  white-space: normal;
}

/* Legal */
.site-footer .guardian-footer-bottom {
  margin-top: 37px;
}
.site-footer .guardian-footer-legal {
  max-width: 575px;
}
.site-footer .fine {
  max-width: none;
  margin: 0;
  color: #818996;
  font-size: 10px;
  line-height: 1.9;
}
.site-footer .fine + .fine {
  margin-top: 12px;
}

/* Guardian */
.site-footer .guardian-footer-image {
  position: absolute;
  z-index: 0;
  bottom: 0;
  right: 0;
  display: block;
  height: 760px;
  max-height: calc(100% - 25px);
  width: auto;
  max-width: none;
  margin: 0;
  object-fit: contain;
  object-position: bottom right;
  mask-image: linear-gradient(#000 0%, #000 88%, transparent 100%);
  -webkit-mask-image: linear-gradient(#000 0%, #000 88%, transparent 100%);
  pointer-events: none;
}

@media (hover: hover) and (pointer: fine) {
  .site-footer .wordmark:hover {
    opacity: 0.65;
  }
  .site-footer .footer-link-column a:hover {
    color: #5869bf;
    text-decoration: underline;
    text-underline-offset: 5px;
  }
  .site-footer .btn-dark:hover {
    background: linear-gradient(#44536e, #293952);
    box-shadow:
      inset 0 1px 0 #ffffff35,
      0 5px 12px #17223824,
      0 0 0 1px #182338;
    transform: translateY(-1px);
  }
}
@media (pointer: coarse) {
  .site-footer .footer-link-column a {
    min-height: 44px;
  }
}

@media (min-width: 701px) and (max-width: 1000px) {
  .site-footer .guardian-footer-inner {
    min-height: 790px;
    padding-top: 50px;
  }
  .site-footer .guardian-footer-content {
    width: 53%;
  }
  .site-footer .guardian-footer-links {
    gap: 25px;
  }
  .site-footer .guardian-footer-image {
    height: 715px;
  }
  .site-footer .footer-invitation {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }
  .site-footer .guardian-footer-legal {
    max-width: 380px;
  }
}

@media (max-width: 700px) {
  .site-footer {
    --footer-gutter: 24px;
  }
  .site-footer .guardian-footer-inner {
    padding: 40px var(--footer-gutter) 25px;
    min-height: 0;
  }
  .site-footer .guardian-footer-content {
    width: 100%;
    max-width: none;
  }
  .site-footer .wordmark,
  html[lang="th"] .site-footer .wordmark {
    font-size: 25px;
    gap: 9px;
  }
  .site-footer .brand-symbol {
    width: 27px;
    height: 27px;
  }
  .site-footer .guardian-footer-tagline {
    font-size: 12px;
    margin: 17px 0 29px;
    max-width: 310px;
  }
  .site-footer .guardian-footer-links {
    gap: 25px;
    max-width: 430px;
  }
  .site-footer .footer-link-column h2,
  html[lang="th"] .site-footer .footer-link-column h2 {
    font-size: 10px;
    margin-bottom: 7px;
  }
  .site-footer .footer-link-column a {
    font-size: 13px;
    min-height: 44px;
  }
  .site-footer .footer-invitation {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    margin-top: 27px;
  }
  .site-footer .footer-invitation h2,
  html[lang="th"] .site-footer .footer-invitation h2 {
    font-size: 17px;
  }
  .site-footer .guardian-footer-bottom {
    display: flex;
    align-items: flex-end;
    min-height: 395px;
    margin-top: 25px;
  }
  .site-footer .guardian-footer-legal {
    width: 45%;
    max-width: 225px;
  }
  .site-footer .fine {
    font-size: 9px;
    line-height: 1.8;
    color: #737d8c;
  }
  .site-footer .fine + .fine {
    margin-top: 14px;
  }
  .site-footer .guardian-footer-image {
    height: 410px;
    max-height: none;
    mask-image: linear-gradient(#000 0%, #000 94%, #0009 100%);
    -webkit-mask-image: linear-gradient(#000 0%, #000 94%, #0009 100%);
  }
}

@media (max-width: 370px) {
  .site-footer {
    --footer-gutter: 21px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .site-footer .btn {
    transition: none;
  }
  .site-footer .btn:active,
  .site-footer .btn-dark:hover {
    transform: none;
  }
}

@media print {
  .site-footer .guardian-footer-inner {
    padding: 25px;
    min-height: 0;
  }
  .site-footer .guardian-footer-content {
    width: 100%;
  }
  .site-footer .guardian-footer-image,
  .site-footer .footer-invitation {
    display: none;
  }
  .site-footer .guardian-footer-bottom {
    min-height: 0;
  }
  .site-footer .guardian-footer-legal {
    width: 100%;
    max-width: none;
  }
}
