/* Everfold Agency — Coming Soon
   Static, dependency-free. Brand tokens match the main Everfold design system. */

@font-face {
  font-family: "Hanken Grotesk";
  src: url("/assets/hanken-grotesk-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329,
    U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2197, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --burgundy: #811018;
  --mist: #e6f2ff;
  --sage: #a3a574;
  --ink: #111111;
  --ink-muted: #4b4b4b; /* 7.7:1 on the pale blue */
  --gutter: clamp(1.25rem, 0.55rem + 3.4vw, 4rem);
  --ease-soft: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-fold: cubic-bezier(0.76, 0, 0.24, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
}

html {
  background-color: var(--mist);
  color: var(--ink);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  font-family: "Hanken Grotesk", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

::selection {
  background-color: var(--burgundy);
  color: #fff;
}

:focus-visible {
  outline: 2px solid var(--burgundy);
  outline-offset: 5px;
  border-radius: 1px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ---------------------------------------------------------------
   Layout: one calm, centred composition with the footer at the end
---------------------------------------------------------------- */
.page {
  display: grid;
  grid-template-rows: 1fr auto;
  min-height: 100vh;
  min-height: 100svh;
}

.stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: clamp(2.75rem, 1.5rem + 6vh, 6rem);
  padding: clamp(4.5rem, 3rem + 7vh, 8rem) var(--gutter) clamp(3rem, 2rem + 4vh, 5rem);
  text-align: center;
}

/* The supplied dot-matrix wordmark, measured from the original artwork. */
.brand {
  width: min(88vw, 62rem);
  color: var(--burgundy);
  font-size: 0;
  line-height: 0;
}

.wordmark {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 941.78 / 178.07;
}

.wordmark svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.message {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 36rem;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--burgundy);
}

.eyebrow::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background-color: currentColor;
}

.headline {
  margin-top: 1.25rem;
  font-size: clamp(2.125rem, 1.35rem + 2.7vw, 3.75rem);
  font-weight: 300;
  line-height: 1.04;
  letter-spacing: -0.038em;
  color: var(--burgundy);
  text-wrap: balance;
}

.lede {
  max-width: 40ch;
  margin-top: 1.375rem;
  font-size: clamp(1rem, 0.94rem + 0.28vw, 1.1875rem);
  line-height: 1.6;
  color: var(--ink-muted);
  text-wrap: pretty;
}

.contact {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  margin-top: clamp(1.75rem, 1.4rem + 1.2vw, 2.5rem);
}

.contact-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 44px;
  padding-inline: 0.25rem;
  font-size: 1.0625rem;
  font-weight: 500;
  letter-spacing: 0.005em;
  color: var(--ink);
  text-decoration: none;
  transition: color 0.3s ease;
}

.contact-link .label {
  background-image: linear-gradient(currentColor, currentColor);
  background-repeat: no-repeat;
  background-position: 0 100%;
  background-size: 100% 1px;
  padding-bottom: 0.15em;
  transition: background-size 0.5s var(--ease-soft);
}

.contact-link .arrow {
  display: block;
  width: 0.75em;
  height: auto;
  color: var(--burgundy);
  transition: transform 0.5s var(--ease-soft);
}

.contact-link:hover {
  color: var(--burgundy);
}

.contact-link:hover .arrow,
.contact-link:focus-visible .arrow {
  transform: translate(2px, -2px);
}

@media (hover: hover) {
  .contact-link:hover .label {
    background-size: 0% 1px;
    background-position: 100% 100%;
  }
}

.address {
  font-size: 0.875rem;
  color: var(--ink-muted);
}

/* ---------------------------------------------------------------
   Footer with a dotted rule, echoing the dot-matrix logo
---------------------------------------------------------------- */
.footer {
  position: relative;
  display: flex;
  justify-content: space-between;
  gap: 0.5rem 2rem;
  padding: 1.5rem var(--gutter) calc(1.5rem + env(safe-area-inset-bottom, 0px));
  font-size: 0.8125rem;
  line-height: 1.5;
  color: var(--ink-muted);
}

.footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: var(--gutter);
  right: var(--gutter);
  height: 4px;
  background-image: radial-gradient(circle at center, rgb(129 16 24 / 0.4) 1.15px, transparent 1.55px);
  background-size: 7px 4px;
  background-repeat: repeat-x;
  background-position: center;
}

@media (max-width: 40rem) {
  .footer {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
}

/* Shorter laptop screens: tighten the vertical rhythm. */
@media (max-height: 50rem) and (min-width: 48rem) {
  .stage {
    gap: 2.5rem;
    padding-top: 3.5rem;
    padding-bottom: 2.5rem;
  }
}

/* Short landscape phones: keep everything comfortably on screen. */
@media (max-height: 30rem) and (orientation: landscape) {
  .stage {
    gap: 2rem;
    padding-top: 2.5rem;
  }

  .brand {
    width: min(70vw, 36rem);
  }
}

/* ---------------------------------------------------------------
   Introduction: the wordmark unfolds from its centre, then the
   message rises into place. CSS only, so nothing waits for scripts.
---------------------------------------------------------------- */
@media (prefers-reduced-motion: no-preference) {
  @keyframes unfold {
    from {
      clip-path: inset(0 50% 0 50%);
      opacity: 0;
    }
    to {
      clip-path: inset(0 0 0 0);
      opacity: 1;
    }
  }

  @keyframes fade {
    from {
      opacity: 0;
    }
    to {
      opacity: 1;
    }
  }

  @keyframes rise {
    from {
      opacity: 0;
      transform: translate3d(0, 0.9rem, 0);
    }
    to {
      opacity: 1;
      transform: none;
    }
  }

  @keyframes settle {
    from {
      transform: scale(1.02);
    }
    to {
      transform: none;
    }
  }

  @keyframes draw {
    from {
      clip-path: inset(0 50% 0 50%);
    }
    to {
      clip-path: inset(0 0 0 0);
    }
  }

  .wordmark {
    animation: settle 2.2s var(--ease-soft) both;
  }

  .wordmark .main {
    animation: unfold 1.4s var(--ease-fold) 0.1s both;
  }

  .wordmark .fine {
    animation: fade 1.1s var(--ease-soft) 0.95s both;
  }

  .eyebrow {
    animation: rise 1s var(--ease-soft) 0.8s both;
  }

  .headline {
    animation: rise 1.1s var(--ease-soft) 0.9s both;
  }

  .lede {
    animation: rise 1.1s var(--ease-soft) 1.1s both;
  }

  .contact {
    animation: rise 1.1s var(--ease-soft) 1.25s both;
  }

  .footer {
    animation: fade 1.2s var(--ease-soft) 1.4s both;
  }

  .footer::before {
    animation: draw 1.6s var(--ease-fold) 1.4s both;
  }
}
