-
-
Copy link
+
+
+
Send them this private link
+
+
+ Copy link
+
+
-
-
-
Open it as they will
-
Save as a file
-
Write another
+
+
+ Open it as they will
+ Save as a file
-
The camera is off. This letter isn’t saved anywhere on this computer; it exists in that link and any file you save. Closing this window forgets it.
+
Write another letter
+
The camera is off. This letter isn’t saved on this computer. It exists only in that link and any file you save, so closing this window forgets it.
diff --git a/src/writer/writer.css b/src/writer/writer.css
index 2f9e384..cb79edb 100644
--- a/src/writer/writer.css
+++ b/src/writer/writer.css
@@ -1,101 +1,147 @@
-/* Heartwritten writer. The same desk and paper as the reader. */
+/* Heartwritten writer. The letter is serif ink on paper; everything around it is quiet UI. */
:root {
- --desk: #e5dfd4;
- --paper: #f7f3ea;
+ --desk: #ebe5da;
+ --paper: #f8f4eb;
--ink: #1c2234;
--muted: #776f5f;
- --on-desk: #2a2a2e;
+ --on-desk: #26262a;
--on-desk-muted: #7a7366;
- --hair: rgba(28, 34, 52, 0.14);
+ --hair: rgba(28, 34, 52, 0.12);
+ --line: rgba(60, 45, 20, 0.16);
+ --card: rgba(255, 252, 245, 0.72);
--stamp: #a8381e;
+ --wax: #9e2b25;
--serif: "Iowan Old Style", Charter, "Bitstream Charter", "Sitka Text", Cambria, Georgia, serif;
+ --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Inter, Roboto, "Helvetica Neue", sans-serif;
--tooth: url("data:image/svg+xml;utf8,
");
color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
- :root { --desk: #161412; --paper: #efe9dd; --on-desk: #ebe3d4; --on-desk-muted: #9b9282; }
+ :root {
+ --desk: #171513; --paper: #efe9dd; --on-desk: #ece4d5; --on-desk-muted: #9d9483;
+ --line: rgba(236, 228, 213, 0.16); --card: rgba(255, 250, 240, 0.05);
+ }
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
background: var(--desk); color: var(--on-desk);
- font: 18px/1.6 var(--serif);
- font-variant-numeric: oldstyle-nums proportional-nums;
+ font: 16px/1.55 var(--sans);
-webkit-font-smoothing: antialiased;
}
main { max-width: 920px; margin: 0 auto; padding: 40px 28px 56px; }
-.smallcaps { font-variant-caps: all-small-caps; letter-spacing: 0.09em; font-size: 17px; margin: 0; }
-.muted { color: var(--muted); }
-.note { color: var(--muted); font-size: 15px; font-style: italic; line-height: 1.45; }
-.fine { color: var(--muted); font-size: 13px; line-height: 1.5; margin: 22px 0 0; }
+.label { font: 600 12.5px/1.3 var(--sans); color: var(--on-desk-muted); margin: 0 0 10px; }
+.note { color: var(--on-desk-muted); font-size: 13.5px; line-height: 1.45; }
+.fine { color: var(--on-desk-muted); font-size: 12.5px; line-height: 1.5; margin: 22px 0 0; }
+/* Buttons */
button { font: inherit; color: inherit; cursor: pointer; background: none; border: 0; padding: 0; }
-button:disabled { opacity: 0.4; cursor: default; }
-button:focus-visible, input:focus-visible { outline: 1.5px solid currentColor; outline-offset: 4px; }
-button.primary {
- background: var(--ink); color: var(--paper);
- font-variant-caps: all-small-caps; letter-spacing: 0.1em; font-size: 18px;
- padding: 11px 22px 12px; border-radius: 2px;
+.btn {
+ display: inline-flex; align-items: center; justify-content: center; gap: 8px;
+ font: 600 15px/1 var(--sans); padding: 13px 22px; border-radius: 999px;
+ transition: background-color 0.15s, border-color 0.15s, opacity 0.15s, transform 0.08s;
}
-button.primary:not(:disabled):hover { background: #2b3450; }
-button.quiet, .links button {
- font-variant-caps: all-small-caps; letter-spacing: 0.09em; font-size: 17px;
- text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 5px;
- text-decoration-color: transparent; transition: text-decoration-color 0.2s;
+.btn:active:not(:disabled) { transform: translateY(1px); }
+.btn:disabled { opacity: 0.38; cursor: default; }
+.btn:focus-visible, input:focus-visible, summary:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
+.btn.primary { background: var(--ink); color: #fbf8f1; }
+.btn.primary:not(:disabled):hover { background: #2c3552; }
+.btn.secondary { border: 1px solid var(--line); background: var(--card); color: var(--on-desk); }
+.btn.secondary:hover { border-color: var(--on-desk-muted); }
+.btn.ghost { color: var(--on-desk-muted); padding: 8px 12px; }
+.btn.ghost:hover { color: var(--on-desk); background: var(--card); }
+.btn.small { font-size: 13px; }
+.btn.link { font: 500 14px var(--sans); color: var(--on-desk-muted); text-decoration: underline; text-underline-offset: 4px; text-decoration-color: var(--line); padding: 6px; }
+.btn.link:hover { color: var(--on-desk); text-decoration-color: currentColor; }
+@media (prefers-color-scheme: dark) {
+ .btn.primary { background: #f3ede1; color: #1c2234; }
+ .btn.primary:not(:disabled):hover { background: #fff; }
+ .btn:focus-visible, input:focus-visible, summary:focus-visible { outline-color: #f3ede1; }
}
-button.quiet:hover, .links button:hover { text-decoration-color: currentColor; }
-input[type="checkbox"] { accent-color: var(--ink); width: 15px; height: 15px; margin: 0 10px 0 0; vertical-align: -2px; }
+
+/* Checkboxes and switches */
+.check { display: flex; gap: 10px; align-items: flex-start; font-size: 14.5px; line-height: 1.45; cursor: pointer; }
+.check input { accent-color: var(--ink); width: 16px; height: 16px; margin: 2px 0 0; flex: none; }
+.switch { appearance: none; -webkit-appearance: none; flex: none; width: 38px; height: 22px; border-radius: 999px; margin: 0; background: rgba(60, 45, 20, 0.2); position: relative; cursor: pointer; transition: background 0.2s; }
+.switch::after { content: ""; position: absolute; top: 2px; left: 2px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.25); transition: transform 0.2s; }
+.switch:checked { background: var(--ink); }
+.switch:checked::after { transform: translateX(16px); }
+@media (prefers-color-scheme: dark) { .switch { background: rgba(236, 228, 213, 0.2); } .switch:checked { background: #d9c9a8; } .check input { accent-color: #d9c9a8; } }
.step { display: none; }
body[data-step="consent"] .step-consent,
body[data-step="write"] .step-write,
body[data-step="sealed"] .step-sealed { display: block; }
-.sheet, .paper {
- background: var(--tooth), var(--paper); color: var(--ink);
- box-shadow: 0 0 0 1px rgba(60, 45, 20, 0.07), 0 30px 50px -36px rgba(40, 28, 10, 0.6);
-}
+.card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; }
+.paper { background: var(--tooth), var(--paper); color: var(--ink); box-shadow: 0 0 0 1px rgba(60, 45, 20, 0.07), 0 30px 50px -36px rgba(40, 28, 10, 0.6); }
-/* 1. Consent */
-.sheet { max-width: 680px; margin: 3vh auto 0; padding: 52px 64px 44px; }
-.wordmark { font-weight: 400; font-style: italic; font-size: 44px; line-height: 1.1; margin: 4px 0 14px; letter-spacing: -0.01em; }
-.lede { font-size: 21px; line-height: 1.5; margin: 0 0 30px; }
-.facts { display: grid; grid-template-columns: 168px 1fr; gap: 12px 24px; margin: 0 0 30px; padding: 24px 0 0; border-top: 1px solid var(--hair); }
-.facts dt { font-variant-caps: all-small-caps; letter-spacing: 0.09em; font-size: 16px; color: var(--muted); line-height: 1.3; padding-top: 0.25em; }
-.facts dd { margin: 0; font-size: 17px; line-height: 1.55; }
-.choices { border: 0; border-top: 1px solid var(--hair); padding: 18px 0 0; margin: 0 0 18px; }
-.choices legend { padding: 0 0 6px; float: left; width: 100%; }
-.choices label { display: block; margin: 6px 0; font-size: 17px; }
-.agree { display: block; padding-top: 18px; border-top: 1px solid var(--hair); margin: 0 0 22px; font-size: 17px; font-style: italic; }
-.row { display: flex; gap: 20px; align-items: center; flex-wrap: wrap; }
-.row .note { flex: 1 1 260px; }
+/* 1. Welcome */
+.welcome { max-width: 600px; margin: 4vh auto 0; }
+.brand { display: flex; align-items: center; gap: 9px; font: 600 14px var(--sans); margin: 0 0 22px; color: var(--on-desk); }
+.brand-dot { width: 14px; height: 14px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #c9473d, var(--wax) 60%, #6f1c18); box-shadow: 0 1px 2px rgba(80, 10, 10, 0.3); }
+.welcome h1 { font: italic 400 42px/1.12 var(--serif); letter-spacing: -0.015em; margin: 0 0 14px; }
+.welcome .lede { font: 19px/1.5 var(--serif); margin: 0 0 30px; color: var(--on-desk); }
+.how { list-style: none; padding: 0; margin: 0 0 26px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
+.how li { display: flex; gap: 10px; align-items: flex-start; }
+.how-n { flex: none; width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--line); display: grid; place-items: center; font: 600 12px var(--sans); color: var(--on-desk-muted); }
+.how b { display: block; font-weight: 600; font-size: 14.5px; }
+.how li span:not(.how-n) { display: block; font-size: 13.5px; color: var(--on-desk-muted); line-height: 1.4; margin-top: 2px; }
+.choices { margin: 0 0 14px; padding: 16px 18px 6px; }
+.choices legend { float: left; width: 100%; padding: 0; }
+.switch-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 10px 0; border-top: 1px solid var(--line); cursor: pointer; clear: both; }
+.switch-row:first-of-type { border-top: 0; }
+.switch-row b { display: block; font-weight: 500; font-size: 15px; }
+.switch-row small { display: block; font-size: 13px; color: var(--on-desk-muted); margin-top: 1px; }
+.privacy { margin: 0 0 26px; font-size: 14px; }
+.privacy summary { cursor: pointer; color: var(--on-desk-muted); font-weight: 500; padding: 6px 2px; list-style: none; display: inline-flex; align-items: center; gap: 8px; border-radius: 6px; }
+.privacy summary::-webkit-details-marker { display: none; }
+.privacy summary::before { content: ""; width: 7px; height: 7px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(-45deg); transition: transform 0.2s; margin-right: 2px; }
+.privacy[open] summary::before { transform: rotate(45deg); }
+.privacy summary:hover { color: var(--on-desk); }
+.facts { display: grid; grid-template-columns: 150px 1fr; gap: 10px 20px; margin: 12px 0 16px; padding: 16px 18px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); }
+.facts dt { font-weight: 600; font-size: 13px; color: var(--on-desk-muted); }
+.facts dd { margin: 0; font-size: 14px; line-height: 1.5; }
+.privacy .check { color: var(--on-desk-muted); font-size: 13.5px; }
+.start { padding-top: 20px; border-top: 1px solid var(--line); }
+.agree { margin: 0 0 16px; }
+.row { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
+.row .note { flex: 1 1 240px; }
/* 2. Writing */
-.live { display: grid; grid-template-columns: 76px 1fr auto; gap: 22px; align-items: center; margin: 0 auto 22px; max-width: 760px; }
-.cam { position: relative; width: 76px; height: 76px; border-radius: 3px; overflow: hidden; background: #2b2926; }
+.live {
+ display: grid; grid-template-columns: 52px 1fr auto; gap: 18px; align-items: center;
+ max-width: 760px; margin: 0 auto 18px; padding: 10px 14px 10px 10px;
+ background: var(--card); border: 1px solid var(--line); border-radius: 18px;
+}
+.cam { position: relative; width: 52px; height: 52px; border-radius: 50%; overflow: hidden; background: radial-gradient(circle at 50% 38%, #4a443c, #26231f); }
.cam video { width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); }
-.rec { position: absolute; left: 7px; top: 7px; width: 7px; height: 7px; border-radius: 50%; background: #d8442a; }
-.camera-off .rec { background: #888; }
-.live-heart canvas { width: 100%; height: 48px; display: block; }
-.live-stats { display: flex; gap: 20px; align-items: baseline; color: var(--on-desk-muted); font-size: 15px; font-style: italic; }
-.live-stats b { font-weight: 400; font-style: normal; font-size: 24px; color: var(--on-desk); margin-right: 3px; }
-.smile-dot { font-variant-caps: all-small-caps; letter-spacing: 0.09em; font-style: normal; opacity: 0.3; transition: opacity 0.4s, color 0.4s; }
-.smile-dot::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: currentColor; margin-right: 6px; vertical-align: 0.15em; }
+.rec { position: absolute; right: 4px; bottom: 4px; width: 9px; height: 9px; border-radius: 50%; background: #e0492d; box-shadow: 0 0 0 2px var(--paper); }
+.camera-off .rec { background: #8a8378; }
+.live-heart { min-width: 0; }
+.live-heart canvas { width: 100%; height: 34px; display: block; }
+.live-stats { display: flex; gap: 16px; align-items: baseline; color: var(--on-desk-muted); font-size: 13px; margin-top: 2px; }
+.live-stats b { font: 600 16px var(--sans); font-variant-numeric: tabular-nums; color: var(--on-desk); margin-right: 2px; }
+.smile-dot { opacity: 0.35; transition: opacity 0.4s, color 0.4s; }
+.smile-dot::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: currentColor; margin-right: 6px; vertical-align: 0.12em; }
.smile-dot.on { opacity: 1; color: #b9842a; }
-.live-side { text-align: right; min-width: 170px; }
-.hint { margin: 0 0 4px; font-size: 15px; font-style: italic; color: var(--stamp); }
+.live-side { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; min-width: 150px; }
+.hint { margin: 0; font-size: 13px; color: var(--stamp); text-align: right; }
.hint[data-ok="true"] { color: var(--on-desk-muted); }
-.sim { margin: 0 0 4px; color: var(--stamp); font-variant-caps: all-small-caps; letter-spacing: 0.09em; font-size: 15px; }
-.live-side .quiet { color: var(--on-desk-muted); }
+.pill { margin: 0; display: inline-block; font: 600 11.5px/1 var(--sans); padding: 5px 9px; border-radius: 999px; }
+.sim { color: var(--stamp); background: rgba(168, 56, 30, 0.1); }
+.pill[hidden] { display: none; }
-.paper { max-width: 760px; margin: 0 auto; padding: 44px 64px 36px; }
-.paper label { display: flex; gap: 12px; align-items: baseline; color: var(--muted); font-variant-caps: all-small-caps; letter-spacing: 0.09em; font-size: 16px; }
+.paper { max-width: 760px; margin: 0 auto; padding: 44px 64px 36px; border-radius: 3px; }
+.paper label { display: flex; gap: 12px; align-items: baseline; }
+.paper label > span { font: 500 13px var(--sans); color: var(--muted); }
.paper input {
border: 0; border-bottom: 1px solid var(--hair); background: transparent;
font: italic 22px var(--serif); color: var(--ink); padding: 2px 2px 4px; flex: 0 1 280px; border-radius: 0;
}
.paper input::placeholder, textarea::placeholder { color: rgba(28, 34, 52, 0.32); -webkit-text-fill-color: rgba(28, 34, 52, 0.32); font-style: italic; }
.paper input:focus { outline: none; border-bottom-color: var(--ink); }
+.paper input:focus-visible { outline: none; }
.field-from { justify-content: flex-end; margin-top: 10px; }
.ink-field { position: relative; margin: 26px 0 20px; min-height: 48vh; }
.ink-mirror, textarea {
@@ -110,43 +156,39 @@ textarea {
background: transparent; color: transparent; -webkit-text-fill-color: transparent; caret-color: var(--ink);
}
textarea::selection { background: rgba(28, 34, 52, 0.16); }
-textarea:focus { outline: none; }
-.write-foot { display: flex; gap: 20px; align-items: center; justify-content: space-between; max-width: 760px; margin: 20px auto 0; }
-.write-foot .note { color: var(--on-desk-muted); font-variant-caps: all-small-caps; font-style: normal; letter-spacing: 0.09em; font-size: 15px; }
+textarea:focus, textarea:focus-visible { outline: none; }
+.write-foot { display: flex; gap: 20px; align-items: center; justify-content: space-between; max-width: 760px; margin: 18px auto 0; }
+.foot-notes { display: flex; flex-direction: column; gap: 2px; }
+.foot-notes .note:empty { display: none; }
/* 3. Sealed */
-.sealed { max-width: 640px; margin: 6vh auto 0; text-align: center; }
-.seal { width: 180px; height: 180px; margin: 0 auto 18px; animation: press 0.7s cubic-bezier(.2, .9, .3, 1.25); filter: drop-shadow(0 8px 8px rgba(60, 10, 10, 0.2)); }
+.sealed { max-width: 560px; margin: 5vh auto 0; text-align: center; }
+.seal { width: 168px; height: 168px; margin: 0 auto 14px; animation: press 0.7s cubic-bezier(.2, .9, .3, 1.25); filter: drop-shadow(0 8px 8px rgba(60, 10, 10, 0.2)); }
.seal svg { width: 100%; height: 100%; display: block; }
@keyframes press { from { transform: scale(1.5) rotate(-8deg); opacity: 0; } }
-.step-sealed h2 { font-style: italic; font-weight: 400; font-size: 44px; margin: 0; }
-.step-sealed .lede { color: var(--on-desk-muted); font-size: 18px; margin: 4px 0 28px; }
-.link-row { display: flex; gap: 18px; align-items: center; margin: 0 auto 8px; }
+.step-sealed h2 { font: italic 400 42px/1.1 var(--serif); margin: 0; }
+.step-sealed .lede { color: var(--on-desk-muted); font-size: 15px; margin: 8px 0 26px; }
+.share { text-align: left; padding: 16px 16px 12px; }
+.link-row { display: flex; gap: 10px; align-items: center; }
.link-row input {
flex: 1; min-width: 0; font: 13px ui-monospace, Menlo, monospace; color: var(--on-desk);
- padding: 8px 0; border: 0; border-bottom: 1px solid var(--on-desk-muted); background: transparent; border-radius: 0;
-}
-#link-note { color: var(--on-desk-muted); }
-.links { justify-content: center; gap: 28px; margin-top: 26px; color: var(--on-desk); }
-.step-sealed .fine { color: var(--on-desk-muted); max-width: 30em; margin: 30px auto 0; }
-@media (prefers-color-scheme: dark) {
- .step-sealed button.primary { background: var(--paper); color: var(--ink); }
+ padding: 12px 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--desk); text-overflow: ellipsis;
}
+#link-note { display: block; margin: 8px 4px 0; }
+#link-note:empty { display: none; }
+.actions { justify-content: center; margin: 20px 0 8px; gap: 10px; }
+.step-sealed .fine { max-width: 30em; margin: 22px auto 0; }
@media (max-width: 700px) {
- main { padding: 0 0 40px; }
- .sheet { padding: 36px 22px 32px; margin: 0; box-shadow: none; }
+ main { padding: 20px 16px 40px; }
+ .welcome h1 { font-size: 34px; }
+ .how { grid-template-columns: 1fr; }
.facts { grid-template-columns: 1fr; gap: 2px; }
.facts dd { margin-bottom: 10px; }
- .live { grid-template-columns: 56px 1fr; padding: 14px 16px 0; }
- .cam { width: 56px; height: 56px; }
- .live-side { grid-column: 1 / -1; text-align: left; }
- .paper { padding: 28px 22px; box-shadow: none; }
- .write-foot { padding: 0 16px; }
- .sealed { padding: 0 20px; }
-}
-@media (prefers-color-scheme: dark) {
- .live { background: var(--tooth), var(--paper); padding: 12px 16px; }
- .live-stats, .live-side .quiet, .hint[data-ok="true"] { color: var(--muted); }
- .live-stats b { color: var(--ink); }
+ .live { grid-template-columns: 44px 1fr; }
+ .cam { width: 44px; height: 44px; }
+ .live-side { grid-column: 1 / -1; flex-direction: row; align-items: center; justify-content: space-between; }
+ .paper { padding: 28px 22px; }
+ .write-foot { flex-direction: column; align-items: stretch; }
+ .link-row { flex-direction: column; align-items: stretch; }
}