[hidden] { display: none !important; }
.unread-badge { display:inline-flex; margin-left:6px; min-width:20px; padding:0 5px; justify-content:center; border-radius:50%; background:#b96b43; color:#fffbee; font:12px/20px var(--sans); }
.unread-badge:empty { display:none; }
.journal-toolbar { flex-wrap:wrap; gap:16px; }
.journal-search { display:flex; gap:8px; flex:1 1 100%; max-width:580px; }
.journal-search input { flex:1; min-width:0; padding:11px 14px; border:1px solid #bbc9bf; border-radius:3px; background:#fffcf3; font:16px/1.5 var(--sans); color:var(--ink); }
.journal-search input:focus-visible { outline:2px solid #bc8e58; outline-offset:2px; }
.discussion-count { display:block; margin-top:6px; font:12px/1.6 var(--sans); color:#59776a; }
.message-status, .read-state { display:inline-block; padding:3px 9px; background:#eee7d4; color:#846841; border-radius:3px; font:12px/1.7 var(--sans); }
.message-status.replied { color:#3d7169; background:#e5ebdc; }
.read-state { margin:8px 0; background:#e6eee7; }
.message-card .message-body { padding:12px 15px; background:#f7f4e9; border-radius:3px 12px 12px; }
.message-card .message-reply { margin-left:20px; border-radius:12px 3px 12px 12px; }
.share-card { padding:24px; margin-bottom:20px; border:1px solid #d6d6bc; border-radius:3px 3px 18px; background:linear-gradient(160deg,#e8f1ee,#fff9e7 65%); overflow-wrap:anywhere; }
.share-card h3 { font-family:var(--display-cn); font-weight:400; }
.share-link { display:block; padding-top:14px; border-top:1px dashed #c5c9b8; font:12px/1.8 var(--sans); text-decoration:underline; }
.account-dock { position: fixed; z-index: 65; bottom: 20px; left: 22px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; max-width: calc(100vw - 100px); padding: 9px 12px; border: 1px solid #ffffffad; border-radius: 18px; background: #fff9ecef; box-shadow: 0 5px 28px #234a561a; backdrop-filter: blur(14px); font: 13px/1.5 system-ui,sans-serif; color: #345967; }
.account-name { max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.system-button { padding: 9px 14px; border: 1px solid #bbc9bf; border-radius: 9px; background: #faf7ed; color: #315866; font: 500 14px/1.4 system-ui,sans-serif; cursor: pointer; }
.system-button:hover { background: #e9edda; }
.system-button.primary { background: #426c6a; color: #fffdf1; border-color: #426c6a; }
.system-button.danger { color: #9b4938; border-color: #dcb3a4; }
.system-button:disabled { opacity: .5; cursor: wait; }
.system-button:focus-visible, .system-dialog input:focus-visible, .system-dialog textarea:focus-visible, .system-dialog select:focus-visible { outline: 3px solid #dfab4e; outline-offset: 3px; }
.system-dialog { width: min(680px, calc(100vw - 28px)); max-height: 88dvh; padding: clamp(22px,5vw,42px); border: 1px solid #c4cbb7; border-radius: 18px; background: #faf7ed; color: #34545d; box-shadow: 0 22px 100px #133c4a55; overflow-y: auto; font: 16px/1.65 system-ui,sans-serif; }
.system-dialog::backdrop { background: #193b4c85; backdrop-filter: blur(5px); }
.system-dialog h2 { margin: 5px 35px 18px 0; font-size: 27px; }
.system-dialog h3 { font-size: 20px; }
.system-dialog .dialog-x { float: right; border: 0; background: transparent; font-size: 28px; color: inherit; cursor: pointer; }
.system-kicker { font: 11px/1.6 system-ui,sans-serif; letter-spacing: .2em; color: #6f8577; }
.system-form { display: grid; gap: 16px; }
.system-field { display: grid; gap: 6px; font-size: 14px; font-weight: 500; }
.system-field input, .system-field textarea, .system-field select { width: 100%; min-width: 0; border: 1px solid #b7c4b9; border-radius: 8px; padding: 11px 12px; background: #fffdf7; color: #294d57; font: 16px/1.65 system-ui,sans-serif; box-sizing: border-box; }
.system-field textarea { resize: vertical; }
.system-check { display: flex; align-items: center; gap: 10px; font-size: 14px; }
.system-check input { width: 18px; height: 18px; }
.system-actions, .system-tabs { display: flex; flex-wrap: wrap; gap: 9px; margin: 16px 0; }
.system-status { min-height: 1.6em; font: 14px/1.7 system-ui,sans-serif; color: #856b49; white-space: pre-wrap; }
.system-status.error { color: #a44331; }
.system-note { font: 14px/1.8 system-ui,sans-serif; color: #657a72; }
.system-empty { padding: 24px; border: 1px dashed #b7c4b9; border-radius: 10px; font: 15px/1.8 system-ui,sans-serif; color: #617b74; }
.message-section { padding-top: 35px; padding-bottom: 65px; }
.message-intro { max-width: 680px; }
.message-board { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 20px; margin-top: 24px; }
.message-card, .manage-card { background: #fffdf4; border: 1px solid #d6dccb; border-radius: 12px; padding: 24px; overflow-wrap: anywhere; }
.message-card p, .manage-card p { white-space: pre-wrap; font: 16px/1.85 system-ui,sans-serif; }
.message-meta, .post-date { display: block; color: #798977; font: 12px/1.8 system-ui,sans-serif; margin-bottom: 8px; }
.message-reply { padding: 12px 16px; border-left: 3px solid #cead68; background: #f3eedf; }
.manage-list { display: grid; gap: 14px; }
.manage-card { padding: 18px; }
.manage-card h3 { margin: 0 0 8px; }
.manage-card .system-actions { margin-bottom: 0; }
.editable-copy { white-space: pre-line; }
.system-journal-art { height: 185px; display: grid; place-content: center; background: linear-gradient(145deg,#cedbd3,#edf0d2); color: #3d665e; }
.system-journal-art span { font-size: 48px; font-weight: 400; }
.system-journal-art small { letter-spacing: .2em; font: 11px system-ui,sans-serif; }
.system-journal-art.life { background: linear-gradient(145deg,#b8d8e6,#f5eccf); }
.system-journal-art.thoughts { background: linear-gradient(145deg,#e2ddc3,#bfd1c0); }
.system-journal-body { padding: 5px 0; }
.system-journal-body p { white-space: pre-wrap; overflow-wrap: anywhere; }
.attached-image, .message-image, .journal-cover { display:block; width:100%; max-height:420px; object-fit:contain; margin:16px 0 4px; border-radius:3px; background:#e9eee5; }
.journal-cover { height:185px; margin:0; object-fit:cover; }
.card-art.has-image { display:block; padding:0; overflow:hidden; }
.image-picker { display:grid; gap:8px; padding:12px; border:1px dashed #becbbb; border-radius:8px; }
.image-picker legend { padding:0 4px; font:500 14px/1.5 var(--sans); }
.image-picker input { max-width:100%; font:13px/1.5 var(--sans); }
.image-picker-preview { max-width:100%; min-height:0; }
.image-picker-preview:empty { display:none; }
.image-picker-preview img { display:block; max-width:100%; max-height:260px; object-fit:contain; border-radius:4px; background:#edf1e9; }
.image-picker .system-status { margin:0; }
.system-draft { color: #99783d; }
.recent-updates { position:relative; z-index:1; width:min(760px,100%); margin:38px 0 4px; padding:22px; border:1px solid #fff4d670; border-radius:3px 3px 18px 3px; background:#faf6e9f2; color:var(--ink); box-shadow:0 8px 28px #163e5015; }
.recent-updates h2 { margin:0 0 15px; font:400 25px/1.5 var(--display-cn); }
.recent-updates .section-script { font-size:20px; }
.recent-updates .system-status:empty { display:none; }
.recent-list { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; }
.recent-entry.system-button { width:100%; display:flex; flex-direction:column; gap:8px; text-align:left; white-space:normal; background:#fffdf5; border:1px solid #d7ddce; border-radius:3px; padding:15px; overflow-wrap:anywhere; }
.recent-entry strong { font:400 18px/1.5 var(--display-cn); }
.recent-entry .message-meta { margin:0; font-size:10px; }
.recent-excerpt { font:12px/1.8 var(--sans); color:#718177; }
.journal-discussion { margin-top:28px; padding-top:22px; border-top:1px dashed #bccabb; }
.journal-discussion h3 { font:400 24px/1.5 var(--display-cn); }
.journal-discussion .manage-list { margin:18px 0; }
.discussion-context { padding:12px 16px; border-left:3px solid var(--orange); background:#eeefdf; overflow-wrap:anywhere; }
@media(max-width:640px) { .recent-list { grid-template-columns:1fr; } .recent-updates { padding:18px; } .recent-entry.system-button { gap:5px; } }
.draft-recovery { padding:16px; background:#edf0df; border:1px dashed #a2b8a0; border-radius:8px; }
.draft-status { margin:0; font-size:12px; }
.journal-preview h3 { font-family:var(--display-cn); font-weight:400; overflow-wrap:anywhere; }
.journal-preview .system-journal-body { padding:12px 0; }
/* Account forms share the site's sky, handwritten headings and letter paper. */
.system-dialog.auth-dialog {
  position: relative;
  width: min(540px, calc(100vw - 28px));
  padding: 138px 38px 28px;
  border: 1px solid #fff7e5;
  border-radius: 5px 5px 20px 5px;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  box-shadow: 0 24px 80px #193d5060;
}
.auth-dialog::before {
  content: '';
  position: absolute;
  inset: 0 0 auto;
  height: 112px;
  background: linear-gradient(90deg,#28688775,#488faf20), url('assets/summer-sky.jpg') 55% 42% / cover;
  border-radius: 0 0 50% 8% / 0 0 14px 8px;
  pointer-events: none;
}
.auth-dialog::after {
  content: '✳';
  position: absolute;
  top: 65px;
  right: 36px;
  color: #ffe5a6;
  font: 46px/1 Georgia,serif;
  transform: rotate(-12deg);
  pointer-events: none;
}
.auth-dialog .dialog-x {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 1;
  float: none;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid #fff8e878;
  border-radius: 50%;
  background: #27566c55;
  color: #fff9e9;
  font: 28px/1 var(--sans);
}
.auth-dialog .dialog-x:hover { background: #27566c99; }
.auth-dialog .system-kicker {
  display: block;
  position: absolute;
  top: 32px;
  left: 38px;
  max-width: calc(100% - 116px);
  color: #fff8e8;
  font: 9px/1.8 var(--sans);
  letter-spacing: .17em;
}
.auth-script {
  display: block;
  width: fit-content;
  color: #9b704c;
  font: 23px/1.5 var(--display-en);
  transform: rotate(-3deg);
}
.auth-dialog h2 {
  margin: 6px 0 26px;
  font: 400 34px/1.4 var(--display-cn);
  letter-spacing: 2px;
}
.auth-dialog .system-form { gap: 18px; }
.auth-dialog .system-field { gap: 8px; font: 15px/1.6 var(--sans); }
.auth-dialog .system-field input {
  padding: 11px 13px;
  border: 1px solid #bacac2;
  border-bottom: 2px solid #9eb7ae;
  border-radius: 3px;
  background: #fffdf6;
  font-family: var(--sans);
  box-shadow: inset 0 2px 5px #526a5a05;
}
.auth-dialog .system-button.primary {
  min-height: 46px;
  margin-top: 5px;
  border: 1px solid #426c6a;
  border-radius: 3px;
  box-shadow: 3px 3px 0 #cdd8c6;
  font: 400 19px/1.5 var(--display-cn);
  letter-spacing: 2px;
}
.auth-dialog .system-button.primary:hover { background: #355c5a; }
.auth-dialog .system-status { margin: 0; min-height: 0; }
.auth-dialog .system-status:empty { margin-top: -18px; }
.auth-dialog .system-tabs { gap: 22px; margin: 22px 0 18px; }
.auth-dialog .system-tabs .system-button {
  padding: 5px 0;
  border: 0;
  border-bottom: 1px solid #b99d77;
  border-radius: 0;
  background: transparent;
  font: 15px/1.6 var(--sans);
}
.auth-dialog .system-tabs .system-button:hover { color: #a35937; border-color: var(--orange); }
.auth-dialog > .system-note {
  margin: 0;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font: 12px/1.9 var(--sans);
}
@media(max-width:640px) {
  .system-dialog.auth-dialog { padding: 122px 24px 24px; }
  .auth-dialog::before { height: 100px; }
  .auth-dialog .system-kicker { left: 24px; max-width: calc(100% - 96px); }
  .auth-dialog::after { top: 62px; right: 28px; font-size: 36px; }
  .auth-dialog h2 { font-size: 30px; margin-bottom: 22px; }
  .auth-script { font-size: 21px; }
}
@media(max-width:640px) { .message-board { grid-template-columns: 1fr; } .account-dock { bottom: 12px; left: 10px; padding: 7px; gap: 5px; } .account-dock .system-button { padding: 7px 9px; font-size: 12px; } .account-name { max-width: 85px; } .system-dialog { padding: 24px 20px; } }
