/* Fonts are served from this domain (SIL Open Font License, texts in /fonts). */
@font-face {
  font-family: "Fraunces Variable";
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url("/fonts/fraunces-latin-soft-normal.woff2") format("woff2-variations");
}

@font-face {
  font-family: "Nunito Variable";
  font-style: normal;
  font-display: swap;
  font-weight: 200 1000;
  src: url("/fonts/nunito-latin-wght-normal.woff2") format("woff2-variations");
}

@font-face {
  font-family: "Caveat Variable";
  font-style: normal;
  font-display: swap;
  font-weight: 400 700;
  src: url("/fonts/caveat-latin-wght-normal.woff2") format("woff2-variations");
}

/* Palette "musgo e latão". */
:root {
  --bg: #e9ecdf;
  --bg-moss: #dce5cf;
  --card: #f5f5ee;
  --ink: #23302a;
  --sub: #56635b;
  --metal-dark: #9c9585;
  --moss: #8fae7e;
  --moss-dark: #5e7f55;
  --link: #3f6136;
  --brass: #e7b85c;
  --brass-ink: #7a5718;
  --petal: #efb3be;
  --petal-center: #f3d27a;
  --night: #23302a;
  --night-text: #edefe4;
  --night-sub: #b9c4b3;
  --spring: cubic-bezier(0.3, 1.6, 0.5, 1);
  --ease-out: cubic-bezier(0.2, 0.8, 0.2, 1);
  --serif: "Fraunces Variable", Georgia, serif;
  --hand: "Caveat Variable", "Segoe Print", cursive;
  color-scheme: light;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  overflow-x: clip;
  background: var(--bg);
  color: var(--ink);
  font-family: "Nunito Variable", ui-rounded, system-ui, sans-serif;
  font-size: 1.125rem;
  line-height: 1.7;
}

::selection {
  background: var(--petal);
  color: var(--ink);
}

a {
  color: var(--link);
  text-underline-offset: 0.2em;
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--moss-dark);
  outline-offset: 4px;
  border-radius: 8px;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: var(--serif);
  font-variation-settings: "SOFT" 100;
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.08;
}

h1 {
  max-width: 15ch;
  margin: 0 auto;
  font-size: clamp(2.4rem, 7.5vw, 4.6rem);
}

h2 {
  max-width: 20ch;
  font-size: clamp(2rem, 5vw, 3.2rem);
}

h3 {
  font-size: 1.6rem;
}

p {
  margin: 0 0 1rem;
}

.wrap {
  width: 100%;
  max-width: 68rem;
  margin: 0 auto;
  padding: 0 1.25rem;
}

.note {
  display: inline-block;
  margin: 0 0 0.5rem;
  font-family: var(--hand);
  font-size: 1.6rem;
  font-weight: 600;
  line-height: 1.1;
  color: var(--brass-ink);
  rotate: -2deg;
}

/* Pollen drifting over the whole page. */
.spores {
  position: fixed;
  inset: 0;
  z-index: 3;
  overflow: hidden;
  pointer-events: none;
}

.spores span {
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brass);
  opacity: 0.35;
}

.spores span:nth-child(1) { left: 6%; top: 18%; }
.spores span:nth-child(2) { left: 18%; top: 72%; width: 4px; height: 4px; }
.spores span:nth-child(3) { left: 30%; top: 36%; }
.spores span:nth-child(4) { left: 44%; top: 86%; width: 5px; height: 5px; }
.spores span:nth-child(5) { left: 57%; top: 14%; width: 4px; height: 4px; }
.spores span:nth-child(6) { left: 68%; top: 58%; }
.spores span:nth-child(7) { left: 80%; top: 28%; width: 7px; height: 7px; }
.spores span:nth-child(8) { left: 90%; top: 76%; width: 4px; height: 4px; }
.spores span:nth-child(9) { left: 12%; top: 46%; width: 5px; height: 5px; }
.spores span:nth-child(10) { left: 36%; top: 6%; width: 4px; height: 4px; }
.spores span:nth-child(11) { left: 74%; top: 92%; }
.spores span:nth-child(12) { left: 95%; top: 44%; width: 5px; height: 5px; }

/* Header. */
.top {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 1.25rem;
  padding-bottom: 0.5rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--serif);
  font-variation-settings: "SOFT" 100;
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
}

.brand img {
  transition: transform 0.5s var(--spring);
}

.brand:hover img {
  transform: rotate(-10deg) scale(1.08);
}

.top__nav {
  display: flex;
  gap: 1.25rem;
}

.top__nav a,
.mail {
  position: relative;
  text-decoration: none;
}

.top__nav a {
  color: var(--ink);
  font-weight: 700;
}

.top__nav a::after,
.mail::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -0.05em;
  height: 3px;
  border-radius: 3px;
  background: currentColor;
  transform: scaleX(0.25);
  transform-origin: left;
  transition: transform 0.5s var(--spring);
}

.top__nav a::after {
  background: var(--brass);
  transform: scaleX(0);
}

.top__nav a:hover::after,
.top__nav a:focus-visible::after,
.mail:hover::after,
.mail:focus-visible::after {
  transform: scaleX(1);
}

/* Hero: the robot frog. */
.hero {
  position: relative;
}

.hero__stage {
  position: relative;
  width: min(100%, 32rem);
  margin: 0 auto;
}

.hint {
  margin: 0 0 0.25rem;
  font-family: var(--hand);
  font-size: 1.45rem;
  font-weight: 600;
  line-height: 1.15;
  color: var(--brass-ink);
  text-align: center;
  rotate: -3deg;
}

.hint__touch,
.hint__arrow {
  display: none;
}

@media (hover: none) {
  .hint__pointer {
    display: none;
  }

  .hint__touch {
    display: inline;
  }
}

@media (min-width: 960px) {
  .hint {
    position: absolute;
    right: 100%;
    top: 22%;
    width: 12rem;
    margin: 0 -1.5rem 0 0;
    text-align: right;
    rotate: -7deg;
  }

  .hint__arrow {
    display: block;
    width: 90px;
    height: 50px;
    margin: 0.25rem 0 0 auto;
    fill: none;
    stroke: var(--brass-ink);
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
  }
}

.frog-btn {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  border-radius: 2rem;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.frog {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

.eye__lid {
  transform-box: fill-box;
  transform-origin: 50% 0;
  transform: scaleY(var(--lid, 0));
}

.eye__lid--droop {
  --lid: 0.4;
}

.eye__glow {
  opacity: 0.2;
  transition: opacity 0.4s ease;
}

.is-awake .eye__glow {
  opacity: 0.55;
}

.frog__throat {
  transform-box: fill-box;
  transform-origin: 50% 0;
}

.frog__petals {
  transform-box: view-box;
  transform-origin: 204px 56px;
  transition: transform 0.6s var(--spring);
}

.frog.is-blooming .frog__petals {
  transform: scale(1.3) rotate(18deg);
}

.bubble {
  position: absolute;
  top: 46%;
  right: -2%;
  margin: 0;
  padding: 0.15rem 0.9rem;
  border: 2px solid var(--ink);
  border-radius: 1.2rem;
  background: var(--card);
  font-family: var(--hand);
  font-size: 1.6rem;
  font-weight: 600;
  line-height: 1.3;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transform: translateY(8px) scale(0.85);
  transition: opacity 0.3s ease, transform 0.45s var(--spring);
}

.bubble::after {
  content: "";
  position: absolute;
  left: -9px;
  top: 50%;
  width: 14px;
  height: 14px;
  border-left: 2px solid var(--ink);
  border-bottom: 2px solid var(--ink);
  background: var(--card);
  transform: translateY(-50%) rotate(45deg);
}

.bubble.is-visible {
  opacity: 1;
  transform: none;
}

.petal {
  position: absolute;
  z-index: 2;
  width: 12px;
  height: 18px;
  margin: -9px 0 0 -6px;
  border: 1.5px solid var(--ink);
  border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
  background: var(--petal);
  pointer-events: none;
  animation: fall 2.6s cubic-bezier(0.3, 0.1, 0.4, 1) var(--delay, 0ms) both;
}

.hero__text {
  padding: 1rem 0 2rem;
  text-align: center;
}

.squiggle {
  position: relative;
  display: inline-block;
  white-space: nowrap;
}

.squiggle svg {
  position: absolute;
  left: -2%;
  bottom: -0.18em;
  width: 104%;
  height: 0.35em;
  overflow: visible;
}

.squiggle path {
  fill: none;
  stroke: var(--brass);
  stroke-width: 5;
  stroke-linecap: round;
}

.lead {
  max-width: 34rem;
  margin: 1.5rem auto 0;
  font-size: clamp(1.15rem, 2.6vw, 1.35rem);
  color: var(--sub);
}

.wave {
  display: block;
  width: 100%;
  height: clamp(40px, 6vw, 90px);
  margin-top: -1px;
  fill: var(--bg-moss);
}

.wave--down {
  fill: var(--bg);
}

.wave--night {
  fill: var(--night);
}

/* Manifesto with the vine that grows as the page scrolls. */
.manifesto {
  background: var(--bg-moss);
}

.manifesto__wrap {
  position: relative;
  padding-top: 3rem;
  padding-bottom: 2rem;
  padding-left: 4.5rem;
}

.vine {
  position: absolute;
  left: 0.75rem;
  top: 3rem;
  width: 48px;
  height: calc(100% - 3rem);
  overflow: visible;
}

.vine__stem {
  fill: none;
  stroke: var(--moss-dark);
  stroke-width: 4;
  stroke-linecap: round;
}

.vine__leaf {
  fill: var(--moss);
  stroke: var(--ink);
  stroke-width: 1.5;
  transform-box: fill-box;
  transform-origin: 50% 100%;
  transition: transform 0.6s var(--spring);
}

.vine__bud {
  transform-origin: 50% 50%;
}

.vine__bud circle:first-child {
  fill: var(--petal);
}

.vine__bud circle:last-child {
  fill: var(--petal-center);
}

.beliefs {
  display: grid;
  gap: 2.25rem;
  margin: 2.5rem 0 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 860px) {
  .beliefs {
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
  }
}

.beliefs__n {
  display: block;
  font-family: var(--hand);
  font-size: 2.4rem;
  font-weight: 700;
  line-height: 1;
  color: var(--brass-ink);
}

.beliefs h3 {
  margin: 0.25rem 0 0.5rem;
}

.beliefs p {
  margin: 0;
  color: var(--sub);
}

/* Apps. */
.apps .wrap {
  padding-top: 2.5rem;
  padding-bottom: 3rem;
}

.app-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 19rem), 1fr));
  gap: 1.5rem;
  margin: 2rem 0 0;
  padding: 0;
  list-style: none;
}

.app-list li {
  display: flex;
}

.app {
  display: flex;
  flex: 1;
  align-items: center;
  gap: 1.1rem;
  padding: 1.25rem 1.4rem;
  border: 2px solid var(--ink);
  border-radius: 1.75rem;
  background: var(--card);
  box-shadow: 5px 6px 0 var(--ink);
  color: var(--ink);
  text-decoration: none;
  transition: transform 0.35s var(--spring);
}

a.app:hover {
  transform: translate(-2px, -4px) rotate(-0.8deg);
}

.app img {
  flex: none;
  width: 72px;
  height: 72px;
  border: 2px solid var(--ink);
  border-radius: 18px;
}

.app__body {
  display: grid;
  gap: 0.15rem;
}

.app__name {
  font-family: var(--serif);
  font-variation-settings: "SOFT" 100;
  font-size: 1.45rem;
  font-weight: 600;
  line-height: 1.2;
}

.app__desc {
  color: var(--sub);
}

.app__url {
  color: var(--link);
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.tag {
  display: inline-block;
  margin-left: 0.35rem;
  padding: 0 0.6rem;
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  background: var(--petal-center);
  font-family: var(--hand);
  font-size: 1.2rem;
  font-weight: 600;
  vertical-align: 0.15em;
  rotate: -5deg;
}

.app--seed {
  border-style: dashed;
  border-color: var(--metal-dark);
  background: transparent;
  box-shadow: none;
}

.sprout {
  flex: none;
  width: 72px;
  height: 72px;
  overflow: visible;
  fill: var(--moss);
  stroke: var(--ink);
  stroke-linecap: round;
  stroke-linejoin: round;
}

.sprout > path {
  fill: none;
  stroke: var(--metal-dark);
}

.sprout__plant {
  transform-box: fill-box;
  transform-origin: 50% 100%;
}

.sprout__plant path:first-child {
  fill: none;
}

/* Contact, at night. */
.contact {
  background: var(--night);
  color: var(--night-text);
  text-align: center;
}

.contact .wrap {
  padding-top: 3rem;
  padding-bottom: 4rem;
}

.contact h2 {
  margin: 0 auto 1.25rem;
}

.contact p {
  max-width: 34rem;
  margin-left: auto;
  margin-right: auto;
  color: var(--night-sub);
}

.contact .note {
  color: var(--brass);
}

.mail {
  display: inline-block;
  font-family: var(--serif);
  font-variation-settings: "SOFT" 100;
  font-size: clamp(1.5rem, 5.5vw, 2.8rem);
  font-weight: 600;
  color: var(--petal-center);
  overflow-wrap: anywhere;
}

.mail:focus-visible {
  outline-color: var(--brass);
}

.note--promise {
  margin-top: 1rem;
  rotate: -3deg;
}

.foot {
  background: var(--night);
  color: var(--night-sub);
  font-size: 0.95rem;
}

.foot__row {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding-top: 1.5rem;
  padding-bottom: 2.5rem;
  border-top: 1px solid rgba(237, 239, 228, 0.12);
}

.foot p {
  margin: 0;
}

/* Page not found. */
.lost {
  padding: 4rem 0 6rem;
  text-align: center;
}

.lost img {
  margin: 0 auto 1.5rem;
}

.lost h1 {
  margin-bottom: 1rem;
}

/* Motion: only for people who have not asked their system for less of it. */
@media (prefers-reduced-motion: no-preference) {
  .spores span {
    opacity: 0;
    animation: drift 16s ease-in-out infinite;
  }

  .spores span:nth-child(2n) { animation-duration: 21s; }
  .spores span:nth-child(3n) { animation-delay: -7s; }
  .spores span:nth-child(4n) { animation-delay: -12s; }
  .spores span:nth-child(5n) { animation-duration: 13s; animation-delay: -3s; }

  .hero__stage {
    animation: emerge 1.3s var(--ease-out) both;
  }

  .hero__text > * {
    animation: rise 0.9s var(--ease-out) both;
  }

  .hero__text > :nth-child(1) { animation-delay: 0.35s; }
  .hero__text > :nth-child(2) { animation-delay: 0.5s; }
  .hero__text > :nth-child(3) { animation-delay: 0.65s; }

  .js .squiggle path {
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
    animation: draw 1.2s 1.1s cubic-bezier(0.6, 0, 0.2, 1) forwards;
  }

  .frog__body {
    transform-box: view-box;
    transform-origin: 200px 345px;
    animation: breathe 5s ease-in-out infinite;
  }

  .frog__flower {
    transform-box: view-box;
    transform-origin: 200px 152px;
    animation: sway 4.5s ease-in-out infinite;
  }

  .frog__pollen circle {
    animation: float 6s ease-in-out infinite;
  }

  .frog__pollen circle:nth-child(2) { animation-delay: -2s; }
  .frog__pollen circle:nth-child(3) { animation-delay: -4s; }
  .frog__pollen circle:nth-child(4) { animation-delay: -1s; }
  .frog__pollen circle:nth-child(5) { animation-delay: -3s; }

  .eye__glow {
    animation: pulse 3.6s ease-in-out infinite;
  }

  .is-awake .eye__glow {
    animation: none;
  }

  .frog.is-blinking .eye__lid {
    animation: blink 0.24s ease-in-out;
  }

  .frog.is-croaking .frog__throat {
    animation: croak 0.6s ease-out;
  }

  .js .reveal {
    opacity: 0;
    translate: 0 28px;
    transition: opacity 0.9s ease, translate 0.9s var(--ease-out);
  }

  .js .reveal.in {
    opacity: 1;
    translate: 0 0;
  }

  .beliefs li:nth-child(2) { transition-delay: 0.12s; }
  .beliefs li:nth-child(3) { transition-delay: 0.24s; }
  .app-list li:nth-child(2) { transition-delay: 0.12s; }

  .js .vine__stem {
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
  }

  .js .vine__leaf {
    transform: scale(0);
  }

  .js .vine__leaf.on {
    transform: scale(1);
  }

  .sprout__plant {
    animation: sway 3.2s ease-in-out infinite;
  }
}

@keyframes drift {
  0% { opacity: 0; transform: translate(0, 0); }
  20% { opacity: 0.75; }
  50% { transform: translate(22px, -46px); }
  80% { opacity: 0.5; }
  100% { opacity: 0; transform: translate(-14px, -100px); }
}

@keyframes emerge {
  from { opacity: 0; translate: 0 60px; scale: 0.94; }
}

@keyframes rise {
  from { opacity: 0; translate: 0 24px; }
}

@keyframes draw {
  to { stroke-dashoffset: 0; }
}

@keyframes breathe {
  0%, 100% { transform: scale(1, 1); }
  50% { transform: scale(1.008, 1.018); }
}

@keyframes sway {
  0%, 100% { transform: rotate(-3deg); }
  50% { transform: rotate(3deg); }
}

@keyframes float {
  0%, 100% { transform: translateY(0); opacity: 0.35; }
  50% { transform: translateY(-14px); opacity: 1; }
}

@keyframes pulse {
  0%, 100% { opacity: 0.14; }
  50% { opacity: 0.32; }
}

@keyframes blink {
  0%, 100% { transform: scaleY(var(--lid, 0)); }
  50% { transform: scaleY(1); }
}

@keyframes croak {
  0%, 100% { transform: scale(1); }
  40% { transform: scale(1.45, 1.6); }
}

@keyframes fall {
  from { opacity: 1; transform: translate(0, 0) rotate(0); }
  to { opacity: 0; transform: translate(var(--dx, 0), 340px) rotate(var(--spin, 180deg)); }
}
