/* Hallmark · v2.0.0 · component scope, a new block in two existing pages · theme: the media page's night wall (user named) · genre: atmospheric · posture: committed · surface: absolute · hero: none, a section near the end · nav: the host page's · footer: the host page's · signature: the phone loop of six things we make, made in HyperFrames */
/* Hallmark · critique · one idea (we make it for you), the phone carries it; one action (/custom/), the email second; a dark band so the loop sits on its own wall on both pages */
/* Hallmark · answered · no drawn phone chrome, a rounded screen only; the loop waits for the viewport, stops under reduced motion and has a pause button */
:root {
  --mfy-wall: #140f33;
  --mfy-wall-hi: #2a1f78;
  --mfy-ink: #fdfbff;
  --mfy-sub: #e2dcff;
  --mfy-pink: #ff3d77;
  --mfy-gold: #ffd166;
  --mfy-dark: #140f33;
  --mfy-line: rgba(255, 255, 255, .22);
  --mfy-glass: rgba(255, 255, 255, .08);
  --mfy-shadow: rgba(0, 0, 0, .5);
  --mfy-font: Rubik, system-ui, sans-serif;
}

.mfy {
  background: radial-gradient(ellipse 80% 70% at 30% 50%, var(--mfy-wall-hi) 0%, var(--mfy-wall) 65%);
  color: var(--mfy-ink);
  font-family: var(--mfy-font);
  padding: 56px 0 64px;
  overflow-x: clip;
}
.mfy__in {
  width: min(100% - 32px, 1040px);
  margin-inline: auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-areas: "head" "phone" "act";
  justify-items: center;
  text-align: center;
  gap: 28px;
}
.mfy__head { grid-area: head; min-width: 0; }
.mfy__act { grid-area: act; min-width: 0; display: grid; justify-items: center; gap: 12px; }
.mfy h2 {
  margin: 0;
  font-family: var(--mfy-font);
  font-size: clamp(30px, 7.6vw, 52px);
  line-height: 1.1;
  font-weight: 800;
  color: var(--mfy-ink);
  overflow-wrap: break-word;
  min-width: 0;
  text-wrap: balance;
}
.mfy__text { margin: 16px auto 0; max-width: 30em; font-size: 18px; line-height: 1.6; color: var(--mfy-sub); }

.mfy__phone { grid-area: phone; position: relative; margin: 0; width: min(60vw, 290px); }
.mfy__phone video {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 2;
  border-radius: 34px;
  background: var(--mfy-wall);
  box-shadow: 0 0 0 2px var(--mfy-line), 0 30px 70px var(--mfy-shadow);
}
.mfy__pause {
  position: absolute;
  inset-block-end: 0;
  inset-inline-end: -52px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid var(--mfy-line);
  background: var(--mfy-wall-hi);
  color: var(--mfy-ink);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background-color .2s ease, transform .2s ease;
}
.mfy__pause svg { width: 20px; height: 20px; }
.mfy__pause .mfy-play { display: none; }
.mfy__pause[aria-pressed="true"] .mfy-play { display: block; }
.mfy__pause[aria-pressed="true"] .mfy-stop { display: none; }
.mfy__pause:hover { background: var(--mfy-dark); }
.mfy__pause:active { transform: scale(.94); }
.mfy__pause[hidden] { display: none; }

.mfy__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 12px 32px;
  border-radius: 999px;
  background: var(--mfy-gold);
  color: var(--mfy-dark);
  font-weight: 800;
  font-size: 19px;
  line-height: 1.2;
  text-decoration: none;
  transition: background-color .2s ease, transform .2s ease;
}
.mfy__cta:hover { background: var(--mfy-ink); }
.mfy__cta:active { transform: scale(.97); }
.mfy__mail-line { margin: 8px 0 0; font-size: 16px; color: var(--mfy-sub); }
.mfy__mail { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 12px; }
.mfy__mail bdi { font-weight: 700; font-size: 18px; overflow-wrap: anywhere; }
.mfy__copy {
  min-height: 44px;
  padding: 8px 20px;
  border-radius: 999px;
  border: 1.5px solid var(--mfy-line);
  background: none;
  color: var(--mfy-ink);
  font: inherit;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  transition: background-color .2s ease;
}
.mfy__copy:hover { background: var(--mfy-glass); }
.mfy__more { color: var(--mfy-ink); font-weight: 700; text-underline-offset: 4px; }
.mfy a:focus-visible, .mfy button:focus-visible { outline: 3px solid var(--mfy-gold); outline-offset: 3px; transition: none; }
.mfy__sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

@media (min-width: 820px) {
  .mfy { padding: 88px 0; }
  .mfy__in {
    grid-template-columns: minmax(0, 1fr) 320px;
    grid-template-areas: "head phone" "act phone";
    justify-items: start;
    align-content: center;
    text-align: start;
    column-gap: 72px;
    row-gap: 28px;
  }
  .mfy__head { align-self: end; }
  .mfy__act { justify-items: start; align-self: start; }
  .mfy__text { margin-inline: 0; font-size: 20px; }
  .mfy__phone { width: 320px; }
  .mfy__mail { justify-content: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  .mfy__cta, .mfy__copy, .mfy__pause { transition: none; }
}
