/* ==========================================================================
   Footer — soft-glow, pastel radial gradients bleeding up from the corners
   ========================================================================== */

.app-footer {
    background:
        radial-gradient(circle at 8% 200%, rgba(246, 210, 230, 1) 0%, rgba(246, 210, 230, 0.62) 14%, rgba(246, 210, 230, 0.24) 28%, transparent 46%),
        radial-gradient(circle at 92% 200%, rgba(204, 232, 247, 1) 0%, rgba(204, 232, 247, 0.66) 16%, rgba(204, 232, 247, 0.24) 30%, transparent 48%);

    color: #444;
    padding: var(--size-xxl) var(--gutter-inline);

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    position: relative;
    font-family: "DM Sans", sans-serif;
    margin: 0 auto;

    overflow: hidden;
    isolation: isolate;
}

/* Minimal variant: no glow, tighter top margin instead of full padding-driven spacing */
.app-footer--minimal {
    margin-top: var(--size-xxl);
    background: none;
}

/* Second, blurred glow layer for a diffused (not hard-edged) light */
.app-footer::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 10% 86%, rgba(255, 192, 220, 0.5) 0%, rgba(255, 192, 220, 0.22) 18%, transparent 36%),
        radial-gradient(circle at 90% 86%, rgba(189, 229, 255, 0.55) 0%, rgba(189, 229, 255, 0.24) 20%, transparent 38%);
    filter: blur(18px);
    pointer-events: none;
    z-index: 0;
}

.app-footer--minimal::before {
    background: none;
}

.footer_wrapper {
    width: 100%;
    margin: 0 auto;

    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 1;
}

/* Columns with info */
.footer-columns {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: flex-start;

    width: 100%;
    margin-bottom: 4rem;
    gap: 5rem;
}

.footer-column:first-child { justify-self: start; }
.footer-column:nth-child(2) { justify-self: center; }
.footer-column:last-child { justify-self: end; }

.footer-column {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 0.4rem;
    width: 100%;
}

.footer-column h4 {
    font-size: 1.3rem;
    font-weight: 600;
    color: #222;
    margin-bottom: 1rem;
}

.footer-column a,
.footer-email-copy {
    text-decoration: none;
    color: #666;
    font-size: 0.95rem;
    line-height: 1.55;
}

.footer-email-copy {
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    font-family: inherit;
    display: inline-block;
    position: relative;
}

/* elements with links (e.g. email, phone, address) */
.footer-column .link,
.footer-column .element {
    transition: color 0.2s ease;
}

.footer-column .link:hover {
    color: var(--color-apple-blue);
    text-decoration: underline;
}

.footer-column .element:hover {
    color: var(--color-apple-blue);
}

.footer-column:first-child a,
.footer-column:nth-child(2) a {
    display: inline-block;
}

.footer-column:first-child a + a {
    margin-top: 0.15rem;
}

.footer-column:nth-child(2) a {
    max-width: 240px;
}

/* Giant faint watermark wordmark */
.footer-logo {
    width: 100%;
    font-size: clamp(3rem, 8vw, 10rem);
    font-weight: 700;

    color: rgba(227, 0, 27, 0.15);

    text-align: center;
    letter-spacing: -0.03em;
    line-height: 1.1;
    white-space: nowrap;

    user-select: none;
}

.footer-rights {
    margin-top: var(--size-lg);
    text-align: center;
    font-size: 0.92rem;
    color: #555;
    line-height: 1.4;
}

/* Legal link, stacked directly under the copyright line — plain text until
   hovered, then underlined and darkened, matching the rest of the
   copyright line rather than reading as a separate call-to-action. */
.footer-legal-link {
    display: block;
    margin-top: 0.5rem;
    color: inherit;
    font-size: inherit;
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-legal-link:hover {
    color: #222;
    text-decoration: underline;
}

@media (max-width: 900px) {
  .footer-columns {
    flex-wrap: wrap;
    gap: 2rem;
  }
}

/* .footer-columns is a grid (1fr auto 1fr), so the flex-wrap above never
   actually applied — below 640px it just kept forcing 3 fixed columns into
   a viewport too narrow for them, clipping the last column off-screen.
   Stack to a single column instead. */
@media (max-width: 640px) {
  .footer-columns {
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 2.5rem;
  }

  .footer-column:first-child,
  .footer-column:nth-child(2),
  .footer-column:last-child {
    justify-self: center;
  }

  .footer-logo {
    font-size: clamp(2.5rem, 15vw, 15rem);
  }

  .site-credit__logo {
    height: 35px !important;
  }
}

/* Site-credit — links out to ungur.ca, nested under the copyright line */
.site-credit {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;

    margin-top: var(--space-8);
    text-align: center;
}

.site-credit__logo {
    height: 45px;
    width: auto;

    transition: opacity 0.2s ease;
}

.site-credit:hover .site-credit__logo {
    opacity: 0.7;
}

/* Copy-to-clipboard tooltip, shown briefly after clicking the email address */
.copied-tooltip {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  background: rgba(30, 30, 32, 0.92);
  color: white;
  font-size: 0.75rem;
  font-weight: 500;
  white-space: nowrap;
  padding: 4px 10px;
  border-radius: 6px;
  pointer-events: none;
}

.copied-tooltip::before {
  content: '';
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 5px solid transparent;
  border-bottom-color: rgba(30, 30, 32, 0.92);
}
