* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: #f9ffbf;
  color: #000000;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-weight: 400;
  overflow-x: hidden;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

h1, h2, p {
  margin: 0;
  font-weight: 400;
}

.container {
  width: min(100%, 1080px);
  margin: 0 auto;
}

.scene {
  position: relative;
}

.step-title {
  position: absolute;
  font-size: clamp(36px, 5.5vw, 64px);
  line-height: 1.05;
}

.container > .scene + .scene {
  margin-top: 320px;
}

.note {
  position: absolute;
  width: 290px;
  max-width: 80%;
  padding: 18px 20px;
  background: #67f7ff;
  border: 1px dotted #000000;
  font-size: 17px;
  line-height: 1.35;
  z-index: 4;
}

.note p + p {
  margin-top: 12px;
}

.note strong, .note b {
  font-weight: 400;
}

.note ul {
  padding-left: 18px;
  margin: 16px 0;
}

.small-note {
  font-size: 13px;
}

.intro {
  min-height: 860px;
  padding-top: 120px;
  text-align: center;
}

.intro h1 {
  font-size: clamp(20px, 3vw, 30px);
}

.table-scene {
  position: relative;
  width: min(55%, 510px);
  aspect-ratio: 1 / 1.04;
  margin: 100px auto 0;
}

.table {
  position: absolute;
  bottom: 0;
  width: 100%;
}

.table-cup {
  position: absolute;
  width: 29%;
  left: 37%;
  bottom: 74%;
}

.scroll-hint {
  font-size: 15px;
  line-height: 1.7;
  margin-top: 42px;
}

.scroll-hint span {
  display: inline-block;
  margin-top: 12px;
}

.ingredients {
  min-height: 470px;
  padding: 100px 20px 20px;
}

.ingredients > div {
  width: 235px;
  margin: 0 auto;
}

.ingredients h2 {
  font-size: 21px;
  margin-bottom: 34px;
}

.ingredients ul {
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 18px;
  line-height: 1.45;
}

.heat {
  height: 880px;
}

.heat .step-title {
  right: 19%;
  top: 70px;
}

.heat-pot {
  position: absolute;
  width: 53%;
  left: 22%;
  top: 190px;
}

.steam {
  position: absolute;
  left: 14%;
  top: 5px;
  width: 27%;
  height: 280px;
}

.smoke {
  position: absolute;
  width: 65%;
  opacity: .65;
}

.js .steam {
  opacity: 0;
}

.js .steam.show {
  opacity: 1;
}

.smoke-one {
  left: 27%;
  top: 36px;
}

.smoke-two {
  left: 0;
  top: 0;
  width: 36%;
}

.heat-note {
  left: 26%;
  top: 780px;
  width: 330px;
}

.grind {
  height: 1160px;
}

.grind-stage {
  position: sticky;
  top: 40px;
  height: 660px;
}

.grind .step-title {
  right: 23%;
  top: 30px;
}

.grind-picture {
  position: absolute;
  left: 15%;
  top: 155px;
  width: 340px;
  max-width: 57%;
  height: 280px;
}

.beans {
  position: absolute;
  inset: 0;
}

.bean {
  position: absolute;
  width: 43%;
}

.bean-one {
  top: 0;
  right: 0;
  transform: rotate(8deg);
}

.bean-two {
  top: 0;
  left: 0;
  transform: rotate(-8deg);
}

.bean-three {
  top: 135px;
  left: 22%;
  width: 47%;
}

.grounds {
  position: absolute;
  width: 100%;
  bottom: 0;
  opacity: 0;
}

.grind-picture.show .beans {
  opacity: 0;
}

.grind-picture.show .grounds {
  opacity: 1;
}

.grind-note {
  left: 57%;
  top: 350px;
  width: 280px;
}

.ground-note {
  left: 12%;
  top: 520px;
  width: 275px;
}

.bloom {
  height: 1110px;
  overflow: hidden;
}

.bloom .step-title {
  right: 20%;
  top: 45px;
  z-index: 4;
}

.bloom-note {
  left: 8%;
  top: 165px;
  width: 310px;
}

.bloom-art {
  position: absolute;
  inset: 0;
}

.pour-pot {
  position: absolute;
  width: 46%;
}

.pot-left {
  left: -16%;
  top: 385px;
  transform: rotate(30deg) scaleX(-1);
}

.pot-right {
  right: -4%;
  top: 235px;
  transform: rotate(-28deg);
}

.water-drop {
  position: absolute;
  width: 27px;
  left: calc(55% - 13px);
}

.water-one {
  top: 457px;
}

.water-two {
  top: 593px;
  width: 24px;
}

.dripper {
  position: absolute;
  width: 43%;
  max-width: 390px;
  bottom: 65px;
  left: 55%;
  transform: translateX(-50%);
  z-index: 2;
}

.brew {
  height: 1900px;
}

.pour .step-title {
  top: 120px;
  left: 8%;
}

.pour-note {
  left: 8%;
  top: 245px;
  width: 320px;
}

.coffee-drops {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.coffee-drop {
  position: absolute;
  left: calc(67% - 24px);
  width: 48px;
}

.coffee-one {
  top: 280px;
}

.coffee-two {
  top: 645px;
}

.coffee-three {
  top: 1010px;
}

.wait {
  position: absolute;
  top: 1240px;
  left: 0;
  width: 100%;
  height: 610px;
}

.wait .step-title {
  top: 70px;
  left: 8%;
}

.server {
  position: absolute;
  width: 290px;
  max-width: 43%;
  left: 67%;
  top: 0;
  transform: translateX(-50%);
  z-index: 2;
}

.server > img {
  width: 100%;
}

#coffee-fill {
  position: absolute;
  bottom: 8%;
  left: 20%;
  width: 60%;
  height: 55%;
  background: #412323;
}

.wait-note {
  top: 460px;
  left: 8%;
  width: 310px;
}

.enjoy {
  min-height: 890px;
  padding: 105px 20px 120px;
  text-align: center;
}

.enjoy .step-title {
  position: relative;
}

.enjoy-cup {
  width: min(52%, 430px);
  margin: 95px auto 0;
}

.enjoy-note {
  position: relative;
  margin: 105px auto 0;
  text-align: left;
  width: 325px;
}

footer {
  max-width: 1080px;
  margin: 0 auto;
  padding: 45px 8% 60px;
  padding-bottom: max(60px, calc(50vh - 160px));
  font-size: 12px;
  line-height: 1.7;
  display: flex;
  justify-content: space-between;
  gap: 25px;
}

.js .note {
  opacity: 0;
}

.js .note.show {
  opacity: 1;
}

@media (max-width: 700px) {
  .container > .scene + .scene {
    margin-top: 200px;
  }
  .note {
    font-size: 14px;
    padding: 13px 14px;
  }
  .small-note {
    font-size: 12px;
  }
  .intro {
    min-height: 680px;
    padding-top: 100px;
  }
  .table-scene {
    width: 73%;
    margin-top: 110px;
  }
  .scroll-hint {
    font-size: 13px;
  }
  .ingredients {
    min-height: 430px;
    padding-top: 70px;
  }
  .ingredients > div {
    width: 190px;
  }
  .ingredients h2 {
    font-size: 17px;
  }
  .ingredients ul {
    font-size: 15px;
  }
  .heat {
    height: calc(500px + 58vw);
  }
  .heat .step-title {
    right: 13%;
    top: 45px;
  }
  .heat-pot {
    width: 72%;
    left: 13%;
    top: 200px;
  }
  .steam {
    left: 6%;
    top: 65px;
    width: 35%;
  }
  .heat-note {
    left: 18%;
    top: calc(320px + 58vw);
    width: 260px;
  }
  .grind {
    height: 1060px;
  }
  .grind-stage {
    top: 20px;
    height: 620px;
  }
  .grind .step-title {
    right: 15%;
    top: 50px;
  }
  .grind-picture {
    left: 9%;
    top: 170px;
    width: 245px;
    height: 215px;
  }
  .bean-three {
    top: 105px;
  }
  .grind-note {
    left: auto;
    right: 7%;
    top: 400px;
    width: 210px;
  }
  .ground-note {
    left: 8%;
    top: 520px;
    width: 235px;
  }
  .bloom {
    height: 990px;
  }
  .bloom .step-title {
    right: 13%;
    top: 30px;
  }
  .bloom-note {
    left: 7%;
    top: 135px;
    width: 245px;
  }
  .pour-pot {
    width: 67%;
  }
  .pot-left {
    left: -28%;
    top: 420px;
  }
  .pot-right {
    right: -27%;
    top: 330px;
  }
  .water-one {
    top: 510px;
    width: 21px;
    left: calc(55% - 10px);
  }
  .water-two {
    top: 625px;
    width: 19px;
    left: calc(55% - 9px);
  }
  .dripper {
    width: 65%;
    bottom: 40px;
  }
  .brew {
    height: 1710px;
  }
  .pour .step-title {
    top: 130px;
    left: 8%;
  }
  .pour-note {
    top: 240px;
    left: 7%;
    width: 57%;
    max-width: 270px;
  }
  .coffee-drop {
    width: 33px;
    left: calc(78% - 16px);
  }
  .coffee-one {
    top: 140px;
  }
  .coffee-two {
    top: 465px;
  }
  .coffee-three {
    top: 830px;
  }
  .wait {
    top: 1090px;
    height: 550px;
  }
  .wait .step-title {
    left: 8%;
    top: 10px;
  }
  .server {
    top: 130px;
    left: 66%;
    width: 235px;
    max-width: 56%;
  }
  .wait-note {
    top: 460px;
    left: 7%;
    width: 260px;
  }
  .enjoy {
    min-height: 760px;
    padding-top: 95px;
  }
  .enjoy-cup {
    width: 74%;
    margin-top: 80px;
  }
  .enjoy-note {
    margin-top: 85px;
    width: 280px;
  }
  footer {
    flex-direction: column;
    gap: 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *, *::before, *::after {
    transition: none !important;
  }
}

.js #coffee-fill {
  opacity: 0;
}

.js .server.show #coffee-fill {
  opacity: 1;
}
