@font-face {
  font-family: Archivo;
  src: url("/fonts/archivo.woff2") format("woff2");
  font-weight: 400 900;
  font-stretch: 62% 125%;
  font-display: swap;
}
:root {
  --ground: #eef0f2;
  --paper: #fff;
  --ink: #161a22;
  --muted: #545b68;
  --line: #d9dde3;
  --line-strong: #b7bec9;
  --perf: #dde1e6;
  --red: #d23b2e;
  --red-press: #b32f24;
  --navy: #24365e;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font:
    400 17px / 1.4 Archivo,
    Arial,
    sans-serif;
}
header,
main,
footer {
  max-width: 592px;
  margin: auto;
  padding: 20px 16px;
}
header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
header > a:first-child {
  white-space: nowrap;
  font-size: 18px;
  font-weight: 800;
  font-stretch: 112%;
  text-decoration: none;
}
main {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 20px;
}
footer {
  font-size: 14px;
  display: flex;
  gap: 20px;
}
h1,
h2,
p {
  margin: 0 0 16px;
}
h1 {
  font-size: 31px;
  line-height: 1;
  font-weight: 800;
  font-stretch: 125%;
  letter-spacing: -0.035em;
  text-wrap: balance;
}
h2 {
  font-size: 21px;
  line-height: 1.15;
  font-weight: 800;
  font-stretch: 112%;
  letter-spacing: -0.02em;
}
p {
  text-wrap: pretty;
}
a {
  color: inherit;
  text-underline-offset: 4px;
  display: inline-block;
  min-height: 44px;
  padding: 10px 0;
}
button,
.button {
  border: 1.5px solid var(--line-strong);
  border-radius: 30px;
  background: var(--paper);
  color: var(--ink);
  font:
    700 16px Archivo,
    Arial,
    sans-serif;
  font-stretch: 112%;
  min-height: 52px;
  padding: 14px 22px;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}
.primary,
button[value="send"] {
  background: var(--red);
  border-color: var(--red);
  color: white;
  font-weight: 800;
}
.primary:active {
  background: var(--red-press);
}
:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}
input,
textarea {
  width: 100%;
  border: 1.5px solid var(--line-strong);
  border-radius: 8px;
  background: var(--paper);
  color: var(--ink);
  font: inherit;
  padding: 12px;
  min-height: 52px;
}
input[readonly] {
  background: #f6f7f8;
}
input[type="checkbox"] {
  width: 24px;
  min-height: 24px;
  vertical-align: middle;
  margin-right: 10px;
}
textarea {
  min-height: 340px;
  resize: vertical;
  font-size: 18px;
  line-height: 1.6;
}
label {
  display: block;
  font-size: 16px;
  font-weight: 600;
  margin: 12px 0 6px;
}
form {
  display: grid;
  gap: 10px;
}
form + form {
  margin-top: 12px;
}
.envelope {
  padding: 8px;
  border-radius: 4px;
  background: repeating-linear-gradient(
    -45deg,
    var(--red) 0 10px,
    var(--paper) 10px 16px,
    var(--navy) 16px 26px,
    var(--paper) 26px 32px
  );
}
.envelope > div {
  padding: 20px;
  background: var(--paper);
  border-radius: 1px;
  position: relative;
}
.hero {
  font-size: clamp(42px, 14vw, 58px);
  line-height: 0.92;
  max-width: 390px;
  margin: 12px 0 20px;
}
.row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}
.row > a {
  padding: 0;
}
.meta {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.3;
}
.stamp-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px 10px;
}
.stamp-grid p {
  margin: 6px 0;
  overflow-wrap: anywhere;
}
.stamp {
  display: inline-flex;
  align-items: flex-end;
  position: relative;
  width: 56px;
  height: 68px;
  padding: 4px;
  border: 4px dotted var(--ground);
  background: var(--member);
  color: white;
  font-weight: 800;
  font-stretch: 125%;
  font-size: 30px;
}
.stamp.small {
  width: 36px;
  height: 44px;
  font-size: 20px;
}
.stamp.empty {
  background: none;
  border: 2px dashed var(--line-strong);
  color: var(--muted);
}
.stamp.draft {
  background: color-mix(in srgb, var(--member) 10%, white);
  border: 2px dashed var(--member);
  color: var(--member);
}
.stamp svg {
  position: absolute;
  right: -20px;
  top: 5px;
  color: var(--ink);
}
.c0 {
  --member: #d23b2e;
}
.c1 {
  --member: #24365e;
}
.c2 {
  --member: #2f6b4f;
}
.c3 {
  --member: #9a4f12;
}
.c4 {
  --member: #5b3e8c;
}
.c5 {
  --member: #0e6e73;
}
.c6 {
  --member: #8a2e5b;
}
.c7 {
  --member: #3d5a2a;
}
.c8 {
  --member: #a23e1a;
}
.c9 {
  --member: #45556b;
}
.letter {
  border-top: 8px solid transparent;
  border-image: repeating-linear-gradient(
      -45deg,
      var(--red) 0 10px,
      var(--paper) 10px 16px,
      var(--navy) 16px 26px,
      var(--paper) 26px 32px
    )
    8;
  background: var(--paper);
  padding: 20px;
  border-radius: 4px;
}
.letter-from {
  position: relative;
  min-height: 90px;
  padding-right: 75px;
}
.letter-from > .stamp {
  position: absolute;
  right: 0;
  top: 0;
}
.postmark {
  position: absolute;
  right: 10px;
  top: 20px;
}
.prose {
  max-width: 65ch;
  font-size: 18px;
  line-height: 1.6;
  overflow-wrap: anywhere;
}
.prose a {
  min-height: 0;
  padding: 0;
}
.prose blockquote {
  border-left: 3px solid var(--line-strong);
  margin-left: 0;
  padding-left: 16px;
}
.stamp-nav {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.stamp-nav a[aria-current="page"] {
  border-bottom: 3px solid var(--ink);
}
nav {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}
.reader-bar {
  position: sticky;
  bottom: 0;
  background: var(--ground);
  padding: 12px 0;
  align-items: center;
}
.panel,
ul {
  background: var(--paper);
  padding: 0 14px;
  list-style: none;
  border-radius: 4px;
}
li {
  padding: 12px 0;
  min-height: 56px;
  border-bottom: 1px solid #eceef1;
}
.archive-link {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}
summary {
  min-height: 44px;
  cursor: pointer;
  padding: 12px 0;
}
pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font: inherit;
}
.first-open .postmark {
  animation: stamp-in 220ms ease-out;
}
@keyframes stamp-in {
  from {
    transform: scale(1.15) rotate(-6deg);
  }
  to {
    transform: scale(1) rotate(0);
  }
}
@view-transition {
  navigation: auto;
}
#post-form {
  view-transition-name: envelope;
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none;
    transition: none;
    view-transition-name: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .first-open .postmark {
    animation: none;
  }
  #post-form {
    view-transition-name: none;
  }
  @view-transition {
    navigation: none;
  }
}
#signin button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
#signin button img {
  flex: none;
}
#signin input + button {
  background: var(--red);
  color: white;
  border-color: var(--red);
}
.circle-navigation {
  max-width: 592px;
  margin: 0 auto;
  padding: 0 16px;
  justify-content: flex-start;
  font-size: 14px;
}

header {
  gap: 16px;
}
.account-link {
  width: 44px;
  min-width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  padding: 0;
  background: var(--ink);
  color: var(--paper);
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

h1,
h2,
.panel a {
  overflow-wrap: anywhere;
}

.signin-letter {
  padding: 8px;
}
.signin-letter-top {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  margin-bottom: 28px;
}
.signin-letter-top p {
  margin: 0;
}
.signin-heading {
  font-size: clamp(34px, 9vw, 46px);
  max-width: 10ch;
}

select {
  width: 100%;
  min-height: 52px;
  border: 1.5px solid var(--line-strong);
  border-radius: 8px;
  padding: 12px;
  color: var(--ink);
  background: var(--paper);
  font: inherit;
}
footer {
  flex-wrap: wrap;
}

.feedback-form textarea {
  min-height: 112px;
  height: auto;
}
