/* Hallmark · custom · Blackbird Cakery · A tiered cake folio in cream, mauve and pear. The tier-size list updates with the cutting plan. */
/* Critique: the trade sets the content and primary interaction. */
@font-face {
  font-family: "cormorant";
  src: url("./fonts/cormorant.woff2") format("woff2");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "work-sans";
  src: url("./fonts/work-sans.woff2") format("woff2");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}
:root {
  --paper: #f4eee8;
  --ink: #332836;
  --line: #c9b9bd;
  --cta: #513347;
  --ctaink: #fbf6e8;
  --body: "work-sans", Arial, sans-serif;
  --display: "cormorant", Georgia, serif;
  --weight: 600;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}
html,
body {
  overflow-x: clip;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: 1rem;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 1rem/1.55 var(--body);
  -webkit-font-smoothing: antialiased;
}
h1,
h2,
h3,
h4,
p,
figure,
dl,
dd {
  margin: 0;
}
h1,
h2,
h3,
h4 {
  font-family: var(--display);
  min-width: 0;
  overflow-wrap: break-word;
  line-height: 1.02;
  font-weight: var(--weight, 600);
}
h1,
h2 {
  text-wrap: balance;
}
p {
  max-width: 62ch;
  text-wrap: pretty;
}
a {
  color: inherit;
  text-underline-offset: 0.22em;
}
a,
button,
select,
input {
  touch-action: manipulation;
}
button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}
button,
select,
summary {
  cursor: pointer;
}
button:disabled {
  cursor: not-allowed;
  opacity: 0.62;
}
button:enabled:active,
.cta:active {
  transform: translateY(1px);
}
:focus-visible {
  outline: 3px solid currentColor;
  outline-offset: 3px;
  box-shadow: 0 0 0 2px Canvas;
}
img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
}
.skip {
  position: absolute;
  z-index: 10;
  top: -8rem;
  left: 1rem;
  background: var(--paper);
  color: var(--ink);
  padding: 0.75rem 1rem;
}
.skip:focus {
  top: 0.5rem;
}
.wrap {
  width: min(calc(100% - clamp(2rem, 8vw, 8rem)), 80rem);
  margin-inline: auto;
}
.mast {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  min-height: 4.7rem;
}
.brand {
  font-family: var(--display);
  font-size: clamp(1.2rem, 2.25vw, 2rem);
  line-height: 1;
  letter-spacing: -0.035em;
  text-decoration: none;
}
.mast nav,
footer .wrap {
  display: flex;
  align-items: center;
  gap: clamp(0.6rem, 1.8vw, 2rem);
  flex-wrap: wrap;
}
.mast nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  text-decoration: none;
  font-size: 0.92rem;
}
.mast nav a:hover {
  text-decoration: underline;
}
.cta,
.takeaway {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.9rem;
  padding: 0.65rem 1.1rem;
  text-decoration: none;
  font-weight: 650;
  border: 1px solid var(--cta);
  background: var(--cta);
  color: var(--ctaink);
}
.cta:hover,
.takeaway:hover {
  text-decoration: underline;
}
.band {
  padding-block: clamp(3rem, 7.2vw, 7.5rem);
}
.band h2 {
  font-size: clamp(2.65rem, 5.5vw, 5.6rem);
  letter-spacing: -0.045em;
  line-height: 1;
  margin-bottom: 1rem;
}
.band h3,
#tool h3 {
  font-size: clamp(1.45rem, 2.6vw, 2.2rem);
  margin-bottom: 0.55rem;
}
.band p + p,
#tool p + p {
  margin-top: 0.7rem;
}
fieldset {
  border: 0;
  padding: 0;
  margin: 0;
  min-width: 0;
}
legend,
label {
  font-weight: 650;
}
.controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin-block: 1rem;
}
.controls label,
.form-label {
  display: grid;
  gap: 0.35rem;
  align-content: start;
  min-width: 0;
}
select,
input[type="number"],
input[type="text"],
textarea {
  min-height: 2.8rem;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  border: 1px solid currentColor;
  border-radius: 0;
  padding: 0.55rem 0.7rem;
  color: var(--ink);
  background: var(--paper);
}
textarea {
  resize: vertical;
  min-height: 4.2rem;
}
.options,
.actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0.7rem 0 1rem;
}
.options button,
.quiet,
.step button {
  border: 1px solid currentColor;
  background: transparent;
  color: inherit;
  min-height: 2.8rem;
  padding: 0.5rem 0.8rem;
}
.options button[aria-pressed="true"] {
  color: var(--ctaink);
  background: var(--cta);
  border-color: var(--cta);
}
.options button:hover,
.quiet:hover {
  text-decoration: underline;
}
.step {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.step button {
  min-width: 2.8rem;
}
.step output {
  min-width: 1.5rem;
  text-align: center;
  font-variant-numeric: tabular-nums;
}
.fine,
figcaption {
  font-size: 0.85rem;
  line-height: 1.45;
}
[role="status"] {
  min-height: 1.4em;
  font-size: 0.9rem;
}
details {
  border-top: 1px solid var(--line);
  margin-top: 1rem;
  padding-top: 0.65rem;
}
summary {
  font-weight: 650;
  min-height: 2.5rem;
}
details p {
  padding-bottom: 0.65rem;
}
address {
  font-style: normal;
  line-height: 1.7;
}
footer {
  padding: 1.7rem 0;
  border-top: 1px solid var(--line);
}
footer .wrap {
  justify-content: space-between;
}
footer p,
footer a {
  font-size: 0.83rem;
}
@media (max-width: 560px) {
  .mast {
    gap: 0.4rem;
    min-height: 4.25rem;
  }
  .mast nav {
    gap: 0.6rem;
  }
  .mast nav a {
    font-size: 0.8rem;
  }
  .mast .brand {
    font-size: 1.2rem;
  }
  .controls {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

:root {
  --pear: #d6d8a8;
  --plum: #513347;
  --mauve: #d9ccd5;
  --cream: #fbf6e8;
}
header {
  border-bottom: 1px solid var(--line);
}
.brand {
  font-style: italic;
  letter-spacing: -0.055em;
  font-size: 2.1rem;
}
.cake-folio {
  max-width: 100rem;
  margin: auto;
  display: grid;
  grid-template-columns: minmax(0, 0.91fr) minmax(0, 1.09fr);
  min-height: 36rem;
  align-items: stretch;
}
.cake-story {
  align-self: center;
  padding: clamp(1.7rem, 5vw, 6rem) max(1.3rem, 7%);
  padding-left: max(4.5vw, calc((100vw - 80rem) / 2));
}
.folio-place {
  display: inline-block;
  border-top: 1px solid var(--plum);
  padding-top: 0.4rem;
  font-size: 0.86rem;
  margin-bottom: 1rem;
}
.cake-story h1 {
  font-size: clamp(5rem, 10vw, 10rem);
  line-height: 0.76;
  letter-spacing: -0.06em;
  font-weight: 600;
}
.cake-story h1 em {
  font-style: normal;
  padding-left: 0.28em;
}
.cake-story p {
  margin: 1.65rem 0;
  max-width: 29ch;
  font-size: 1.18rem;
}
.cake-folio figure {
  position: relative;
  min-height: 33rem;
  margin-left: 4%;
  border-left: 1.15rem solid var(--pear);
}
.cake-folio img {
  position: absolute;
  inset: 0;
  height: 100%;
  object-position: 52% center;
}
.cake-folio figcaption {
  position: absolute;
  bottom: 1rem;
  left: 0;
  max-width: 85%;
  background: var(--cream);
  padding: 0.55rem 0.95rem;
}
.flavour-index,
.cake-visit {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 8%;
  align-items: start;
}
.flavour-lines article {
  border-top: 1px solid var(--plum);
  padding: 0.65rem 0 1.05rem;
}
.flavour-lines h3 {
  font-size: clamp(2rem, 3.5vw, 3.4rem);
  margin: 0;
}
.tier-book {
  background: var(--mauve);
}
.tier-heading {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 2rem;
}
.tier-heading p {
  max-width: 34ch;
}
.figure-book {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: 5%;
  margin-top: 1.5rem;
}
.cake-model {
  background: var(--cream);
  border: 1px solid var(--plum);
  padding: clamp(1rem, 2.6vw, 2.4rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
}

.cake-model figcaption {
  max-width: 34ch;
}

.cake-visit {
  align-items: center;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.88fr);
}
.cake-visit img {
  height: clamp(15rem, 26vw, 25rem);
}
.cake-visit address {
  margin-top: 1rem;
}
@media (max-width: 710px) {
  .cake-folio,
  .flavour-index,
  .figure-book,
  .cake-visit {
    grid-template-columns: minmax(0, 1fr);
    gap: 1.5rem;
  }
  .cake-folio {
    gap: 0;
    min-height: 0;
  }
  .cake-story {
    padding: 1.7rem 5% 2rem;
  }
  .cake-story h1 {
    font-size: clamp(5.2rem, 20vw, 8rem);
  }
  .cake-folio figure {
    min-height: 0;
    height: auto;
    margin-left: 7%;
  }
  .cake-folio img {
    position: static;
    height: clamp(14rem, 53vw, 25rem);
  }
  .cake-folio figcaption {
    position: static;
    max-width: none;
    background: var(--cream);
  }
  .tier-heading {
    display: block;
  }
  .mast nav a:first-child {
    display: none;
  }
  .mast .brand {
    font-size: 1.55rem;
  }
}

/* Cutting elevation */
.atelier-front {
  width: min(1270px, 92%);
  margin: 2rem auto 3.7rem;
}
.atelier-front > header {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 2rem;
  border-bottom: 1px solid #74576a;
  padding-bottom: 0.75rem;
}
.atelier-front h1 {
  font-size: clamp(4.1rem, 8.8vw, 9.8rem);
  font-weight: 500;
  line-height: 0.88;
  letter-spacing: -0.048em;
}
.atelier-front h1 em {
  font-weight: 400;
}
.atelier-front > header p {
  max-width: 21em;
}
.atelier-board {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: clamp(1rem, 5vw, 5rem);
  margin-top: 1rem;
  align-items: center;
}
.atelier-board figure {
  margin: 0;
  min-width: 0;
  text-align: right;
}
.atelier-board figure img {
  display: block;
  width: 100%;
  height: clamp(240px, 31vw, 400px);
  object-fit: cover;
  object-position: 50% 45%;
}
.atelier-board figcaption {
  position: static;
  color: #54444f;
  padding: 0.3rem 0;
  font-size: 0.76rem;
}
.cut-plate {
  color: #513c4c;
  margin: auto;
  max-width: 600px;
  padding: 0.4rem;
}
.cut-plate header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  border-bottom: 3px double #866d79;
}
.cut-plate header span {
  font: clamp(1.8rem, 3.5vw, 3.8rem) var(--display);
}
.cut-plate header strong,
.cut-plate p {
  font-size: 0.89rem;
}

.knife-plan {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0.6rem 0;
}
.knife-plan :is(button, .front-key) {
  padding: 0.55rem 0.65rem;
  border: 1px solid #765d6f;
  border-radius: 0;
  background: transparent;
  color: #513c4c;
  cursor: pointer;
  font-size: 0.86rem;
}
.knife-plan :is(button, .front-key):is([aria-pressed="true"], [data-default]) {
  background: #5b4153;
  color: #fffaf0;
}
.cut-plate a {
  font-weight: bold;
}

@media (max-width: 730px) {
  .atelier-front {
    margin-top: 1.1rem;
  }
  .atelier-front > header {
    display: block;
  }
  .atelier-front h1 {
    font-size: clamp(3.35rem, 13vw, 7rem);
  }
  .atelier-front > header p {
    margin-top: 0.6rem;
  }
  .atelier-board {
    grid-template-columns: 1fr;
    gap: 0.4rem;
  }
  .atelier-board figure img {
    height: clamp(265px, 90vw, 450px);
    object-fit: contain;
    background: #e9ded6;
  }
  .cut-plate {
    padding: 0;
    max-width: none;
  }
}

.atelier-front > header {
  justify-content: flex-start;
}
.atelier-front > header p {
  margin-left: auto;
}

@media (max-width: 730px) {
  .atelier-front > header p {
    margin-left: 0;
  }
}

/* The printed panel is available before the interactive controls load. */
#front-panel [data-front-preview] .front-key {
  cursor: default;
}
#front-panel [data-front-preview] a.front-key {
  cursor: pointer;
}
:where(.front-key, .front-value) {
  display: inline-block;
  box-sizing: border-box;
  font: inherit;
  line-height: inherit;
  text-align: center;
}

@media (max-width: 740px) {
}

/* Keep printed labels on the same lines as their interactive counterparts. */
#front-panel [data-setting-width] {
  display: inline-grid;
  justify-items: center;
  align-items: center;
}
#front-panel [data-setting-width]::before,
#front-panel [data-setting-width] > span {
  grid-area: 1/1;
}
#front-panel [data-setting-width]::before {
  content: attr(data-setting-width);
  visibility: hidden;
}

.atelier-front > header {
  justify-content: space-between;
}
.tier-size-line {
  font: clamp(1.8rem, 3.5vw, 3.3rem)/1.1 var(--display);
  margin: 0.85rem 0;
}
.tier-sizes {
  list-style: none;
  padding: 0;
  margin: 0.9rem 0;
  width: 100%;
}
.tier-sizes li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  border-bottom: 1px solid #ad99a4;
  padding: 0.38rem 0;
}
.cake-model {
  align-items: stretch;
  text-align: left;
}
.cut-plate {
  width: 100%;
}
.knife-plan {
  padding-block: 0.35rem;
}
