/* Site footer — layout after the Figma reference (1429:5783), in the homepage yellow */
.site-footer {
  --sf-yellow: #ffe136;
  --sf-ink: #122039;
  --sf-muted: color-mix(in srgb, var(--sf-ink) 62%, var(--sf-yellow));
  position: relative; overflow: hidden; isolation: isolate;
  background: var(--sf-yellow); color: var(--sf-ink);
  font-family: "Unbounded", system-ui, sans-serif; font-weight: 300;
}

/* Paper grain, like the textured panel in the reference */
.site-footer::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 .55 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  opacity: .16; mix-blend-mode: multiply;
}
/* The hidden dithered picture and hover reveal come from assets/dither.js (data-dither on the footer) */
.sf-secrets { display: none; }

.sf-inner { padding: clamp(20px, 2.2vw, 32px) clamp(16px, 2.2vw, 32px);   /* same space above the top copy and below the bottom copy */ }
.sf-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 24px; }
.sf-status { display: flex; gap: 10px; margin: 0; font-size: clamp(12px, .9vw, 14px); line-height: 1.4; }
.sf-dot {
  flex: none; width: 10px; height: 10px; margin-top: 4px; border-radius: 50%;
  background: var(--sf-ink); box-shadow: 0 0 0 0 rgba(18, 32, 57, .35);
  animation: sf-pulse 2.6s ease-out infinite;
}
@keyframes sf-pulse { 0% { box-shadow: 0 0 0 0 rgba(18,32,57,.35); } 70%, 100% { box-shadow: 0 0 0 8px rgba(18,32,57,0); } }

.site-footer a { color: inherit; text-decoration: none; }
.sf-totop { font-size: clamp(12px, .9vw, 14px); white-space: nowrap; }
.sf-totop span { display: inline-block; margin-left: 4px; font-size: .85em; transition: transform .3s cubic-bezier(.22,.8,.2,1); }
.sf-totop:hover span { transform: translateY(-3px); }

.sf-message {
  max-width: 21em; margin: clamp(72px, 9vw, 160px) auto 0; text-align: center; text-wrap: balance;
  font-weight: 300; font-size: clamp(22px, 2.1vw, 36px); line-height: 1.25;
}
.sf-message a { background: linear-gradient(currentColor, currentColor) 0 100% / 100% 1px no-repeat; padding-bottom: 1px; transition: background-size .35s ease; }
.sf-message a:hover { background-size: 100% 2px; }

/* Bottom row: contact sentence on the left, place on the right */
.sf-bottom {
  display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 24px;
  margin-top: clamp(240px, 23vw, 400px);   /* empty middle: keeps the footer's height */
}
/* Same size, colour and style as the copy at the top */
.sf-credit, .sf-made { margin: 0; font-size: clamp(12px, .9vw, 14px); line-height: 1.4; color: var(--sf-ink); }
/* the contact sentence, bottom left; its links carry the ↗ and an underline that draws in left to right on hover */
.sf-credit { max-width: 24em; text-wrap: balance; }
.sf-link { background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; padding-bottom: 1px; transition: background-size .4s cubic-bezier(.22,.8,.2,1); }
.sf-link:hover, .sf-link:focus-visible { background-size: 100% 1px; }
.sf-link span { display: inline-block; margin-left: 3px; font-size: .85em; transition: transform .3s cubic-bezier(.22,.8,.2,1); }
.sf-link:hover span { transform: translate(2px, -2px); }
/* it sits on the footer's bottom edge, so its "Copied" pill rises above the link */
.sf-credit .sf-copied { top: auto; bottom: calc(100% + 8px); }
.sf-made { justify-self: end; display: flex; align-items: center; gap: 10px; }
.sf-made svg { width: 1.45em; height: 1.45em; }

/* Click-to-copy email: a small "Copied ✓" pill slides in underneath the link */
.sf-copy-wrap { position: relative; display: inline-block; }
.sf-copied {
  position: absolute; z-index: 2; top: calc(100% + 10px); left: 50%;
  display: flex; align-items: center; gap: 10px; white-space: nowrap;
  padding: 7px 10px 7px 14px; border-radius: 999px;
  background: rgba(255, 255, 255, .78); border: 1px solid rgba(18, 32, 57, .1);
  box-shadow: 0 6px 18px rgba(18, 32, 57, .08);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif; font-size: 14px; font-weight: 400; line-height: 1;
  letter-spacing: 0; color: var(--sf-ink);
  opacity: 0; transform: translate(-50%, -6px); pointer-events: none;
  transition: opacity .25s ease, transform .35s cubic-bezier(.22, .8, .2, 1);
}
.sf-copied small { display: flex; align-items: center; gap: 4px; font-size: 12px; color: rgba(18, 32, 57, .5); }
.sf-copied.is-on { opacity: 1; transform: translate(-50%, 0); }

.sf-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

@media (max-width: 720px) {
  .sf-top { gap: 16px; }
  .sf-status br { display: none; }   /* let the line wrap naturally on phones */
  .sf-message { margin-top: 56px; }
  .sf-bottom { grid-template-columns: 1fr; margin-top: 140px; row-gap: 32px; }
  .sf-made { justify-self: start; }
  .sf-copied { font-size: 13px; }
}
@media (prefers-reduced-motion: reduce) {
  .sf-dot { animation: none; }
  .site-footer, .sf-copied { transition: none; }
}
