/* Tim Kranen */
:root { color-scheme: light; font: 100%/1.5 "Atkinson Hyperlegible Next", system-ui, sans-serif; color: #183a32; background: #dee7df; }
* { box-sizing: border-box; }
body { margin: 0; }
.desk, .receipt { min-height: 100svh; display: grid; align-content: center; justify-items: center; padding: clamp(1rem,5vw,4rem); }
.paper { width: min(100%, 36rem); padding: clamp(1.5rem,5vw,3.8rem); border-top: .45rem solid #203f35; background: #fffcf0; box-shadow: .4rem .45rem 0 #bcccbf; }
h1 { font: normal clamp(2.4rem,6vw,4rem)/1.05 "Iowan Old Style", Georgia, serif; letter-spacing: -.05em; margin: 0 0 2rem; }
form { display: grid; gap: .65rem; }
label { font-weight: 650; }
small { font-weight: normal; }
input, select, textarea, button { font: inherit; border-radius: .2rem; }
input, select, textarea { width: 100%; padding: .75rem; background: #fffef8; color: inherit; border: 1px solid #789084; }
input[type=file] { margin-bottom: .75rem; }
textarea { resize: vertical; }
button { justify-self: start; margin-top: .7rem; padding: .7rem 1.25rem; background: #244c40; border: 0; color: white; cursor: pointer; }
button:disabled { opacity: .7; }
:focus-visible { outline: 3px solid #9e6508; outline-offset: 2px; }
#error { color: #942e1c; }
.receipt { gap: 1rem; }
.receipt h1 { font-size: 2rem; margin: 0; }
.receipt a { color: inherit; }
.display { min-height: 100svh; display: grid; place-items: center; background: #202824; }
.card { container-type: inline-size; display: flex; flex-direction: column; overflow: hidden; width: min(100vw,60svh,480px); aspect-ratio: 3/5; background: #28332f; color: #fffef1; }
.receipt .card { width: min(100%,43svh,480px); }
.card img { display: block; flex: 1 1 0; width: 100%; min-height: 0; object-fit: cover; object-position: center; }
.words, .empty p { margin: 0; padding: 7%; font: normal 8cqw/1.28 "Iowan Old Style", Georgia, serif; overflow-wrap: anywhere; white-space: pre-wrap; }
.note, .empty { justify-content: center; }
@font-face { font-family: "Postcard Chalk"; src: url("/chalk.ttf") format("truetype"); font-weight: 700; font-display: swap; }

.card.photo {
  align-items: center;
  justify-content: center;
  background-color: #28332f;
  background-image: radial-gradient(ellipse at 24% 16%, #ffffff09, transparent 62%),
                    repeating-linear-gradient(174deg, transparent 0 6px, #ffffff03 7px, transparent 8px 13px);
}
.instant-print {
  position: relative;
  flex: 0 1 auto;
  width: 91cqw;
  height: 97cqw;
  min-height: 0;
  margin: 5cqw 0;
  padding: 2.3cqw 2.3cqw 7.5cqw;
  background: #faf7ec;
  box-shadow: 0.5cqw 1.4cqw 1.6cqw #0a100e70;
  transform: rotate(-1.5deg);
}
.instant-print.portrait { height: 130cqw; }
.instant-print.landscape { height: 77cqw; }
.instant-print::after {
  content: "";
  position: absolute;
  top: -2.4cqw;
  left: 37%;
  width: 26%;
  height: 5.5cqw;
  transform: rotate(3deg);
  background: repeating-linear-gradient(90deg, #ffffff12 0 1px, transparent 1px 3px), #d6c99edc;
  clip-path: polygon(1% 0, 100% 0, 98% 30%, 100% 50%, 98% 80%, 99% 100%, 0 100%, 2% 70%, 0 45%, 2% 18%);
}
.instant-print img { width: 100%; height: 100%; object-fit: cover; }
.photo .chalk-caption, .photo .ink-caption {
  flex: 0 0 auto;
  width: 94cqw;
  height: 45cqw;
  margin-bottom: 3cqw;
  object-fit: contain;
}
.photo .words {
  flex: 0 0 auto;
  width: 100%;
  padding: 1cqw 6cqw 5cqw;
  font: 700 7.5cqw/1.16 "Postcard Chalk", Georgia, serif;
  text-align: center;
}

.illustrated img { object-fit: contain; }
.receipt .art-status { margin: 0; }

.review { padding: clamp(1rem,4vw,3rem); }
.samples { display: flex; flex-wrap: wrap; gap: 1rem; margin-bottom: 1rem; }
.samples a { text-decoration: none; }
.samples .card { width: min(80vw, 300px); }
.review-link { display: inline-block; margin-top: 1.4rem; color: inherit; }

.card[data-style="vintage"] { background: #f4e7c9; color: #194958; }
[data-style="vintage"] .instant-print { transform: none; padding: 1.6cqw; border: 0.6cqw solid #194958; box-shadow: 0.9cqw 0.9cqw #bc503d; }
[data-style="vintage"] .instant-print::after { content: none; }
[data-style="vintage"] .words { font-family: Georgia, serif; }
.ink-caption { mix-blend-mode: multiply; }

.card[data-style="sunday-comic"] { background: #fff6df; color: #202027; }
.card[data-style="field-journal"] { background: #f2eedc; color: #39432d; }
.card[data-style="matchbook"] { background: #efdab6; color: #172b44; }
.card[data-style="cut-paper"] { background: #f8efdf; color: #2d3557; }
.card[data-style="storybook"] { background: #fbf3e4; color: #4e4237; }

[data-style="sunday-comic"] .instant-print,
[data-style="matchbook"] .instant-print,
[data-style="storybook"] .instant-print {
  transform: none;
  padding: 1cqw;
  border: .65cqw solid currentColor;
  box-shadow: none;
}
[data-style="sunday-comic"] .instant-print::after,
[data-style="matchbook"] .instant-print::after,
[data-style="storybook"] .instant-print::after { content: none; }
[data-style="matchbook"] .instant-print { box-shadow: 1cqw 1cqw #b94132; }
[data-style="storybook"] .instant-print { border-radius: 5cqw; overflow: hidden; }
[data-style="field-journal"] .instant-print { padding: 1.5cqw; transform: rotate(1deg); }
[data-style="cut-paper"] .instant-print { background: #ed866e; padding: 2cqw; box-shadow: 1.4cqw 1.6cqw #465c92; }
[data-style="cut-paper"] .instant-print::after { background: #eab84e; }
.card[data-style]:not([data-style="blackboard"]) .words { font-family: Georgia, serif; }
