@use '../settings/colors';
@use '../settings/fonts';
@use '../settings/grid';
@use '../settings/indent';
.poem {
  font-family: fonts.$font-family-serif;
  color: #222;
  margin: 0 0 1.25rem 0;
  .stanza {
    margin: 0 0 1.25rem 0;
    padding: 0;
    display: block;
    @include grid.fluid-type(15px, 24px);
    line-height: 1.35;
    .line {
      white-space: pre-wrap;
      text-indent: -1em;
      padding-left: 1em;
      display: inline-block;
      .indent {
        letter-spacing: 0.2rem;
        @media (max-width: 480px) {
          letter-spacing: 0.17rem;
        }
      }
    }
  }
  &.nowrap {
    .line {
      white-space: pre;
      padding-right: 1rem;
    }
  }
  &.justify {
    .stanza {
      text-align: justify;
      text-justify: inter-word;
    }
  }
  &.untitled {
    .stanza:first-of-type {
      margin-top: 1.5rem;
    }
  }
}

.poem[data-book-slug='tulips-and-chimneys'] {
  &[data-poem-slug='amores-iv'] {
    @include indent.spacing(11, 0.14rem, 0.13rem);
  }
  &[data-poem-slug='amores-vii'] {
    @include indent.spacing(14, 0.1rem, 0.85rem);
    @include indent.spacing(15, 0.135rem, 0.12rem);
  }
  &[data-poem-slug='amores-viii'] {
    @include indent.spacing(2, 0.14rem, 0.13rem);
    @include indent.spacing(8, 0.17rem, 0.16rem);
    @include indent.spacing(20, 0.175rem, 0.165rem);
  }
  &[data-poem-slug='chansons-innocentes-i'] {
    @include indent.spacing(19, 0.35rem, 0.33rem);
    @include indent.spacing(21, 0.35rem, 0.33rem);
  }
  &[data-poem-slug='chansons-innocentes-ii'] {
    @include indent.spacing(14, 0.35rem, 0.33rem);
  }
  &[data-poem-slug='chansons-innocentes-iii'] {
    @include indent.spacing(2, 0.18rem, 0.16rem);
    @include indent.spacing(3, 0.18rem, 0.16rem);
    @include indent.spacing(6, 0.15rem, 0.1333rem);
  }
  &[data-poem-slug='impressions-iv'] {
    @include indent.spacing(5, 0.11rem, 0.095rem);
  }
  &[data-poem-slug='impressions-v'] {
    @include indent.spacing(8, 0.145rem, 0.125rem);
  }
  &[data-poem-slug='orientale-i'] {
    @include indent.spacing(6, 0.18rem, 0.17rem);
    @include indent.spacing(13, 0.15rem, 0.14rem);
    @include indent.spacing(20, 0.17rem, 0.16rem);
    @include indent.spacing(27, 0.15rem, 0.14rem);
  }
  &[data-poem-slug='orientale-vi'] {
    @include indent.spacing(58, 0.1rem, 0.09rem);
  }
  &[data-poem-slug='portraits-viii'] {
    @include indent.spacing(5, 0.18rem, 0.165rem);
    @include indent.spacing(7, 0.18rem, 0.165rem);
    @include indent.spacing(9, 0.22rem, 0.2rem);
    @include indent.spacing(14, 0.15rem, 0.145rem);
  }
  &[data-poem-slug='portraits-ix'] {
    @include indent.spacing(27, 0.15rem, 0.14rem);
  }
  &[data-poem-slug='portraits-x'] {
    @include indent.spacing(23, 0.15rem, 0.14rem);
  }
  &[data-poem-slug='sonnets-unrealities-ii'] {
    @include indent.spacing(16, 0.225rem, 0.2125rem);
  }
  &[data-poem-slug='sonnets-unrealities-iv'] {
    @include indent.spacing(7, 0.18rem, 0.17rem);
  }
  &[data-poem-slug='sonnets-unrealities-v'] {
    @include indent.spacing(9, 0.22rem, 0.21rem);
  }
  &[data-poem-slug='sonnets-actualities-ii'] {
    @include indent.spacing(14, 0.18rem, 0.17rem);
  }
  &[data-poem-slug='sonnets-actualities-iii'] {
    @include indent.spacing(9, 0.15rem, 0.14rem);
  }
  &[data-poem-slug='sonnets-actualities-iv'] {
    @include indent.spacing(13, 0.15rem, 0.14rem);
  }
}

.poem[data-book-slug='and'] {
  &[data-poem-slug='and-seven-poems-i'] {
    @include indent.spacing(1, 0.17rem, 0.16rem);
    @include indent.spacing(10, 0.16rem, 0.15rem);
  }
  &[data-poem-slug='and-seven-poems-vi'] {
    @include indent.spacing(1, 0.155rem, 0.145rem);
    @include indent.spacing(6, 0.17rem, 0.165rem);
  }
  &[data-poem-slug='and-seven-poems-ii'] {
    @include indent.spacing(13, 0.1725rem, 0.1625rem);
  }
  &[data-poem-slug='and-seven-poems-iv'] {
    @include indent.spacing(2, 0.28rem, 0.27rem);
    @include indent.spacing(3, 0.16rem, 0.15rem);
    @include indent.spacing(7, 0.27rem, 0.26rem);
    @include indent.spacing(13, 0.16rem, 0.15rem);
    @include indent.spacing(23, 0.185rem, 0.16rem);
  }
  &[data-poem-slug='and-seven-poems-vii'] {
    @include indent.spacing(15, 0.155rem, 0.145rem);
  }
  &[data-poem-slug='and-seven-poems-v'] {
    @include indent.spacing(39, 0.18rem, 0.17rem);
  }
  &[data-poem-slug='portraits-xi'] {
    @include indent.spacing(17, 0.17em, 0.16rem);
  }
  &[data-poem-slug='portraits-xii'] {
    @include indent.spacing(57, 0.17em, 0.16rem);
  }
  &[data-poem-slug='sonnets-actualities-xxiv'] {
    @include indent.spacing(2, 0.075rem, 0.7rem);
  }
  &[data-poem-slug='sonnets-realities-i'] {
    @include indent.spacing(12, 0.12rem, 0.11rem);
    @include indent.spacing(14, 0.16rem, 0.15rem);
  }
  &[data-poem-slug='sonnets-realities-ii'] {
    @include indent.spacing(3, 0.13rem, 0.12rem);
    @include indent.spacing(8, 0.32rem, 0.31rem);
    @include indent.spacing(10, 0.14rem, 0.13rem);
  }
  &[data-poem-slug='sonnets-realities-iii'] {
    @include indent.spacing(12, 0.155em, 0.145rem);
  }
  &[data-poem-slug='sonnets-realities-iv'] {
    @include indent.spacing(7, 0.1rem, 0.11rem);
    @include indent.spacing(13, 0.14rem, 0.13rem);
    @include indent.spacing(19, 0.23rem, 0.22rem);
  }
  &[data-poem-slug='sonnets-realities-vi'] {
    @include indent.spacing(6, 0.15rem, 0.14rem);
    @include indent.spacing(8, 0.13rem, 0.12rem);
    @include indent.spacing(16, 0.14rem, 0.13rem);
  }
  &[data-poem-slug='sonnets-realities-vii'] {
    @include indent.spacing(5, 0.17rem, 0.16rem);
    @include indent.spacing(9, 0.14rem, 0.13rem);
    @include indent.spacing(16, 0.16rem, 0.15rem);
  }
  &[data-poem-slug='sonnets-realities-viii'] {
    @include indent.spacing(7, 0.23rem, 0.22rem);
    @include indent.spacing(16, 0.18rem, 0.17rem);
  }
  &[data-poem-slug='sonnets-realities-ix'] {
    @include indent.spacing(4, 0.18rem, 0.17rem);
  }
  &[data-poem-slug='sonnets-realities-xi'] {
    @include indent.spacing(14, 0.14rem, 0.13rem);
  }
  &[data-poem-slug='sonnets-realities-xxi'] {
    @include indent.spacing(11, 0.15rem, 0.14rem);
  }
  &[data-poem-slug='sonnets-realities-xxii'] {
    @include indent.spacing(11, 0.185rem, 0.175rem);
    @include indent.spacing(15, 0.14rem, 0.13rem);
  }
  &[data-poem-slug='sonnets-actualities-iii'] {
    @include indent.spacing(12, 0.16rem, 0.15rem);
  }
  &[data-poem-slug='sonnets-actualities-iv'] {
    @include indent.spacing(7, 0.18rem, 0.17rem);
    @include indent.spacing(12, 0.18rem, 0.17rem);
  }
  &[data-poem-slug='sonnets-actualities-v'] {
    @include indent.spacing(5, 0.16rem, 0.15rem);
  }
  &[data-poem-slug='sonnets-actualities-viii'] {
    @include indent.spacing(4, 0.18rem, 0.17rem);
    @include indent.spacing(12, 0.18rem, 0.17rem);
  }
  &[data-poem-slug='sonnets-actualities-ix'] {
    @include indent.spacing(3, 0.18rem, 0.17rem);
    @include indent.spacing(7, 0.18rem, 0.17rem);
    @include indent.spacing(12, 0.14rem, 0.13rem);
  }
  &[data-poem-slug='sonnets-actualities-xii'] {
    @include indent.spacing(9, 0.15rem, 0.14rem);
    @include indent.spacing(11, 0.15rem, 0.14rem);
  }
  &[data-poem-slug='sonnets-actualities-xiii'] {
    @include indent.spacing(12, 0.25rem, 0.24rem);
  }
  &[data-poem-slug='sonnets-actualities-xvii'] {
    @include indent.spacing(7, 0.16rem, 0.15rem);
    @include indent.spacing(11, 0.13rem, 0.12rem);
    @include indent.spacing(13, 0.16rem, 0.15rem);
  }
  &[data-poem-slug='sonnets-actualities-xviii'] {
    @include indent.spacing(1, 0.16rem, 0.15rem);
    @include indent.spacing(11, 0.23rem, 0.22rem);
    @include indent.spacing(13, 0.18rem, 0.17rem);
  }
  &[data-poem-slug='sonnets-actualities-xxii'] {
    @include indent.spacing(6, 0.16rem, 0.15rem);
  }
  &[data-poem-slug='sonnets-actualities-xxiii'] {
    @include indent.spacing(8, 0.16rem, 0.15rem);
  }
  &[data-poem-slug='post-impressions-v'] {
    @include indent.spacing(9, 0.21rem, 0.2rem);
  }
  &[data-poem-slug='post-impressions-vi'] {
    @include indent.spacing(21, 0.21rem, 0.2rem);
    @include indent.spacing(22, 0.225rem, 0.215rem);
    @include indent.spacing(23, 0.225rem, 0.215rem);
  }
  &[data-poem-slug='post-impressions-x'] {
    @include indent.spacing(5, 0.16rem, 0.15rem);
    @include indent.spacing(18, 0.16rem, 0.15rem);
  }
  &[data-poem-slug='post-impressions-xii'] {
    @include indent.spacing(18, 0.16rem, 0.15rem);
  }
  &[data-poem-slug='portraits-ix'] {
    @include indent.spacing(6, 0.14rem, 0.13rem);
    @include indent.spacing(15, 0.17rem, 0.16rem);
  }
}

.poem[data-book-slug='xli-poems'] {
  &[data-poem-slug='songs-xi'] {
    @include indent.spacing(5, 0.15rem, 0.14rem);
    @include indent.spacing(6, 0.15rem, 0.14rem);
    @include indent.spacing(11, 0.15rem, 0.14rem);
    @include indent.spacing(12, 0.15rem, 0.14rem);
    @include indent.spacing(14, 0.14rem, 0.13rem);
  }
  &[data-poem-slug='chansons-innocentes-ii'] {
    @include indent.spacing(7, 0.25rem, 0.24rem);
    @include indent.spacing(13, 0.15rem, 0.14rem);
  }
  &[data-poem-slug='portraits-ii'] {
    @include indent.spacing(10, 0.35rem, 0.34rem);
    @include indent.spacing(15, 0.02rem, 0.01rem);
    @include indent.spacing(21, 0.085rem, 0.075rem);
    @include indent.spacing(24, 0.085rem, 0.075rem);
  }
  &[data-poem-slug='portraits-iv'] {
    @include indent.spacing(11, 0.15rem, 0.14rem);
  }
  &[data-poem-slug='portraits-v'] {
    @include indent.spacing(5, 0.065rem, 0.055rem);
    @include indent.spacing(10, 0.085rem, 0.075rem);
  }
  &[data-poem-slug='portraits-vi'] {
    @include indent.spacing(6, 0.16rem, 0.15rem);
  }
  &[data-poem-slug='sonnets-vii'] {
    @include indent.spacing(1, 0.14rem, 0.13rem);
    @include indent.spacing(4, 0.16rem, 0.15rem);
    @include indent.spacing(14, 0.17rem, 0.16rem);
  }
  &[data-poem-slug='portraits-viii'] {
    @include indent.spacing(3, 0.28rem, 0.15rem);
    @include indent.spacing(11, 0.08rem, 0.07rem);
    @include indent.spacing(19, 0.08rem, 0.07rem);
    @include indent.spacing(25, 0.16rem, 0.15rem);
    @include indent.spacing(28, 0.215rem, 0.205rem);
    @include indent.spacing(30, 0.115rem, 0.105rem);
  }
  &[data-poem-slug='portraits-ix'] {
    @include indent.spacing(20, 0.16rem, 0.15rem);
    @include indent.spacing(28, 0.075rem, 0.65rem);
  }
  &[data-poem-slug='sonnets-ix'] {
    @include indent.spacing(8, 0.15rem, 0.14rem);
    @include indent.spacing(10, 0.15rem, 0.14rem);
    @include indent.spacing(17, 0.17rem, 0.16rem);
  }
  &[data-poem-slug='sonnets-xi'] {
    @include indent.spacing(2, 0.175rem, 0.165rem);
    @include indent.spacing(5, 0.175rem, 0.165rem);
    @include indent.spacing(16, 0.2rem, 0.19rem);
  }
  &[data-poem-slug='sonnets-xii'] {
    @include indent.spacing(9, 0.16rem, 0.15rem);
  }
  &[data-poem-slug='sonnets-xiv'] {
    @include indent.spacing(14, 0.16rem, 0.15rem);
  }
  &[data-poem-slug='sonnets-xv'] {
    @include indent.spacing(14, 0.16rem, 0.15rem);
  }
  &[data-poem-slug='sonnets-xvi'] {
    @include indent.spacing(5, 0.12rem, 0.11rem);
    @include indent.spacing(6, 0.01rem, 0.01rem);
    @include indent.spacing(9, 0.14rem, 0.13rem);
  }
}

.poem[data-book-slug='is-5'] {
  &[data-poem-slug='forward'] {
    .stanza .line {
      text-indent: 1em;
      padding-left: 0;
      max-width: 800px;
      text-align: justify;
    }
  }
  &[data-poem-slug='five-americans-i'] {
    @include indent.spacing(6, 0.165rem, 0.155rem);
  }
  &[data-poem-slug='five-americans-iv'] {
    @include indent.spacing(2, 0.1rem, 0.09rem);
  }
  &[data-poem-slug='one-iii'] {
    @include indent.spacing(8, 0.22rem, 0.215rem);
  }
  &[data-poem-slug='one-vi'] {
    @include indent.spacing(2, 0.155rem, 0.15rem);
    @include indent.spacing(3, 0.155rem, 0.15rem);
    @include indent.spacing(4, 0.155rem, 0.15rem);
    @include indent.spacing(14, 0.17rem, 0.15rem);
    @include indent.spacing(15, 0.17rem, 0.15rem);
    @include indent.spacing(16, 0.17rem, 0.15rem);
    @include indent.spacing(20, 0.17rem, 0.15rem);
    @include indent.spacing(21, 0.17rem, 0.15rem);
    @include indent.spacing(22, 0.17rem, 0.15rem);
  }
  &[data-poem-slug='one-xl'] {
    writing-mode: vertical-rl;
    .stanza {
      margin-left: 0.5rem;
    }
    .line {
      padding: 0;
    }
  }
  &[data-poem-slug='one-xxii'] {
    @include indent.spacing(24, 0.17rem, 0.165rem);
  }
  &[data-poem-slug='one-xxxi'] {
    @include indent.spacing(37, 0.16rem, 0.15rem);
  }
  &[data-poem-slug='one-xxxviii'] {
    .stanza .line {
      text-indent: 1em;
      padding-left: 0;
      max-width: 850px;
    }
  }
  &[data-poem-slug='two-x'] {
    @include indent.spacing(16, 0.18rem, 0.165rem);
  }
  &[data-poem-slug='three-iv'] {
    @include indent.spacing(6, 0.145rem, 0.14rem);
    @include indent.spacing(15, 0.17rem, 0.15rem);
  }
  &[data-poem-slug='three-vi'] {
    @include indent.spacing(31, 0.12rem, 0.11rem);
  }
  &[data-poem-slug='three-vii'] {
    @include indent.spacing(9, 0.21rem, 0.2rem);
  }
  &[data-poem-slug='three-viii'] {
    [data-line-number='14'] {
      .indent {
        display: none;
        white-space: normal;
      }
      padding-left: 220px;
    }
  }
  &[data-poem-slug='three-ix'] {
    @include indent.spacing(9, 0.175rem, 0.15rem);
    @include indent.spacing(21, 0.1rem, 0.11rem);
    @include indent.spacing(29, 0.175rem, 0.15rem);
  }
  &[data-poem-slug='four-iii'] {
    @include indent.spacing(14, 0.145rem, 0.14rem);
    @include indent.spacing(16, 0.18rem, 0.175rem);
  }
  &[data-poem-slug='four-xi'] {
    @include indent.spacing(7, 0.145rem, 0.14rem);
    @include indent.spacing(18, 0.145rem, 0.14rem);
  }
  &[data-poem-slug='four-xv'] {
    @include indent.spacing(12, 0.145rem, 0.14rem);
    @include indent.spacing(25, 0.21rem, 0.17rem);
  }
  &[data-poem-slug='five-ii'] {
    @include indent.spacing(8, 0.14rem, 0.13rem);
  }
}
