*{box-sizing:border-box}
html,body{margin:0;padding:0;background:transparent;color:#000}
body{font-family:Jost,"Helvetica Neue",Arial,sans-serif;font-weight:400;
  -webkit-font-smoothing:antialiased}

/* The canvas fills the frame the website gives it: as wide as the frame and
   as tall as it, never under 360. */
.postit{
  position:relative;overflow:hidden;
  width:100%;
  height:100vh;
  height:100svh;
  min-height:360px;
  container-type:inline-size;
  --paper-sat:1;           /* the paper is the old site's yellow (#fff959 to #fffcbc), coloured in the files */
  --paper-light:1;
  --ring-sat:1;            /* the pencil is the old site's red (#bf2f10), coloured in the files */
  --ring-light:1;
  --trim:1.4%;             /* extra trim on the paper's edge */
}

/* The lines stand in the middle of the canvas, over the wall's centre; the
   notes around them are laid out by hero.js. */
.postit__caption{position:absolute;inset:0;pointer-events:none}
.postit__wall{position:absolute;left:max(3.4%,20px);right:max(3.4%,20px);top:0;bottom:0}

.postit__items{position:absolute;right:0;top:0}
.postit__item{position:absolute;right:0;top:0}   /* size and place set by hero.js */
.postit__item div{perspective:1000px}

.postit__logo{
  position:absolute;left:50%;top:calc(50% - var(--lift,0px));transform:translate(-50%,-50%);
  width:clamp(150px,19cqw,300px);height:auto;margin:0;opacity:0;color:#000;pointer-events:none;z-index:1}
.postit__text{
  position:absolute;left:50%;top:calc(50% - var(--lift,0px));transform:translate(-50%,-50%);
  width:min(52rem,44cqw);   /* narrow enough that the notes beside it, two a side on desktop, come early */
  margin:0;padding:0;opacity:0;
  text-align:center;text-wrap:balance;
  font-size:clamp(20px,1.9cqw,40px);line-height:1.3;font-weight:400;letter-spacing:0;
}
@container (max-width:379px){
  .postit__text{width:88cqw;font-size:clamp(16px,4.7cqw,21px)}
}
/* A tablet standing upright: the canvas is tall and as wide as a phone's
   twice over, so the lines can be set larger and a little wider. */
@media (max-aspect-ratio:4/5) and (min-width:380px){
  .postit__text{width:min(52rem,64cqw);font-size:clamp(28px,4.8cqw,46px)}
  /* the word mark with them: it stood at 19cqw, small beside lines this large */
  .postit__logo{width:clamp(150px,38cqw,420px)}
}

/* Paper, ring and handwriting are congruent cut-outs of the same note, so each
   layer lies unchanged over the whole note. */
.postit__item__wrap,.postit__item__label{position:absolute;inset:0}
.postit__item__sheet,.postit__item__ring,.postit__item__text{
  position:absolute;left:-4.73%;top:-4.73%;width:109.45%;height:109.45%;
  display:block;opacity:0;
  object-fit:contain}   /* never stretch: rather leave an edge than distort the paper */
.postit__item__sheet{transform-origin:top left}
.postit__item__paper{position:absolute;inset:0;width:100%;height:100%;display:block;object-fit:contain;
  filter:saturate(var(--paper-sat)) brightness(var(--paper-light));
  clip-path:inset(calc(var(--pad,4.32%) + var(--trim)))}

/* A soft shadow under each note's paper, as large as the paper after its
   clip-path and turning with it. A box-shadow inside the turned sheet, not a
   drop-shadow filter around it: Safari composites the turned sheet as a layer
   of its own and leaves it out of a filter on its parent. Sized in cqw so it
   scales with the notes, never less than a pixel below them: on a phone the
   calc() would turn negative and lift the shadow above the note. */
.postit__item__shadow{position:absolute;inset:calc(var(--pad,4.32%) + var(--trim));
  box-shadow:0 max(.5px, calc(.45cqw - 4px)) .05cqw rgba(0,0,0,.063),0 max(1px, calc(1cqw - 7px)) .18cqw rgba(0,0,0,.035)}
.postit__item__ring{
  -webkit-mask-image:conic-gradient(from -95deg,#000 0%,rgba(0,0,0,0) 0%);
          mask-image:conic-gradient(from -95deg,#000 0%,rgba(0,0,0,0) 0%);
  filter:saturate(var(--ring-sat)) brightness(var(--ring-light));
}
