/* Shape hosted beta: sign-in, Account menu, welcome, legal pages, sharing. Last updated: 2026-10-26. */
:root { --h-bg: #f5f0e6; --h-card: #fffdf8; --h-ink: #1d1b18; --h-soft: #6b645a; --h-line: #e2d9c8; --h-accent: #2f5d50; --h-danger: #9b2c22; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --h-bg: #181614; --h-card: #221f1c; --h-ink: #efe8dc; --h-soft: #a59c8f; --h-line: #3a352f; --h-accent: #8cc1b0; --h-danger: #f08a7e; } }
:root[data-theme="dark"] { --h-bg: #181614; --h-card: #221f1c; --h-ink: #efe8dc; --h-soft: #a59c8f; --h-line: #3a352f; --h-accent: #8cc1b0; --h-danger: #f08a7e; }

.hosted-login { margin: 0; background: var(--h-bg); color: var(--h-ink); font: 17px/1.55 -apple-system, system-ui, sans-serif; }
.hosted-login main { max-width: 480px; margin: 0 auto; padding: 56px 16px; }
.hosted-login h1 { font: 400 40px Georgia, serif; margin: 0 0 6px; }
.hosted-login h2 { font-size: 15px; margin: 32px 0 6px; }
.hosted-login .lede { color: var(--h-soft); }
.hosted-login label { display: block; font-size: 14px; margin: 18px 0 6px; }
.hosted-login input[type=email] { width: 100%; box-sizing: border-box; font: inherit; padding: 11px 12px; border-radius: 10px; border: 1px solid var(--h-line); background: var(--h-card); color: var(--h-ink); }
.hosted-login button { margin-top: 12px; font: inherit; border: 0; border-radius: 10px; padding: 11px 16px; background: var(--h-accent); color: var(--h-card); cursor: pointer; }
.hosted-login a { color: var(--h-accent); }
.hosted-login .fine, .hosted-account .fine { color: var(--h-soft); font-size: 14px; }

.hosted-account-btn { position: fixed; left: 16px; bottom: 16px; z-index: 50; font: 14px -apple-system, system-ui, sans-serif; padding: 8px 12px; border-radius: 999px; border: 1px solid var(--h-line); background: var(--h-card); color: var(--h-ink); cursor: pointer; }
.hosted-account { width: min(520px, calc(100vw - 32px)); border: 1px solid var(--h-line); border-radius: 14px; background: var(--h-card); color: var(--h-ink); font: 16px/1.5 -apple-system, system-ui, sans-serif; padding: 20px; }
.hosted-account::backdrop { background: rgba(0, 0, 0, .35); }
.hosted-account h2 { font: 400 26px Georgia, serif; margin: 0; }
.hosted-account h3 { font-size: 14px; margin: 18px 0 4px; letter-spacing: .02em; }
.hosted-account input[type=password], .hosted-account input[name=confirm] { width: 100%; box-sizing: border-box; font: 15px ui-monospace, monospace; padding: 9px 10px; border-radius: 8px; border: 1px solid var(--h-line); background: var(--h-bg); color: var(--h-ink); margin: 6px 0; }
.hosted-account .row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.hosted-account .row.end { justify-content: flex-end; margin-top: 18px; }
.hosted-account button { font: inherit; font-size: 14px; border: 1px solid var(--h-line); border-radius: 8px; padding: 7px 12px; background: var(--h-bg); color: var(--h-ink); cursor: pointer; }
.hosted-account button.danger { color: var(--h-danger); border-color: var(--h-danger); margin-top: 6px; }
.hosted-account a { color: var(--h-accent); }
.hosted-account details { margin-top: 16px; }

/* Not part of the hosted beta yet: Finance, Library and Fitness stay on the Mac app. */
body.shape-hosted .shape-card:has([data-act="finance"]), body.shape-hosted .shape-card:has([data-act="library"]), body.shape-hosted .shape-card:has([data-act="training"]) { display: none; }
.hosted-account .legal { margin-top: 18px; }
.hosted-account .row .grow { flex: 1; }
.hosted-account .row .btn-link { align-self: center; font-size: 14px; }
.hosted-account button.primary { background: var(--h-accent); border-color: var(--h-accent); color: var(--h-card); }
.hosted-welcome p { margin: 10px 0; }
.hosted-legal .draft { display: inline-block; font-size: 12px; letter-spacing: .06em; text-transform: uppercase; border: 1px dashed var(--h-soft); border-radius: 6px; padding: 2px 8px; color: var(--h-soft); }
.hosted-legal main { max-width: 640px; }
.hosted-legal h2 { font-size: 17px; margin: 28px 0 6px; }
.hosted-legal li { margin: 4px 0; }
.hosted-login footer { margin-top: 40px; font-size: 14px; color: var(--h-soft); }
.hosted-share-btn { left: 104px; }
.hosted-share label { display: block; margin: 8px 0; }
.hosted-share select, .hosted-share input[name=n] { display: block; width: 100%; box-sizing: border-box; font: 15px -apple-system, system-ui, sans-serif; padding: 8px 10px; border-radius: 8px; border: 1px solid var(--h-line); background: var(--h-bg); color: var(--h-ink); margin-top: 4px; }
.hosted-share .share-list { list-style: none; padding: 0; margin: 0; }
.hosted-share .share-list li { padding: 10px 0; border-top: 1px solid var(--h-line); }
.hosted-share .fb-pass { border-top: 1px solid var(--h-line); padding: 10px 0; }
.hosted-share blockquote { margin: 0 0 6px; font: 16px/1.5 Georgia, serif; color: var(--h-ink); }
.hosted-share .fb-c { margin: 6px 0 10px; }
.hosted-share .fb-c p { margin: 2px 0; }
.hosted-share .fb-tag { font-size: 12px; color: var(--h-soft); border: 1px solid var(--h-line); border-radius: 999px; padding: 0 7px; white-space: nowrap; }
.hosted-share label.share-check { display: flex; gap: 8px; align-items: center; }
.hosted-share { max-height: calc(100vh - 48px); overflow: auto; }
.hosted-read main { max-width: 640px; }
.hosted-read .r-head h1 { margin: 6px 0 8px; }
.hosted-read .r-in { display: block; width: 100%; max-width: 280px; box-sizing: border-box; font: 15px -apple-system, system-ui, sans-serif; padding: 8px 10px; border-radius: 8px; border: 1px solid var(--h-line); background: var(--h-card); color: var(--h-ink); margin-top: 4px; }
.hosted-read .r-book { font: 20px/1.6 "EB Garamond", Georgia, serif; margin-top: 28px; }
.hosted-read .r-ch { font: 400 22px "EB Garamond", Georgia, serif; text-align: center; margin: 36px 0 16px; }
.hosted-read .r-ch span { display: block; font-size: 15px; color: var(--h-soft); }
.hosted-read .r-who .r-in { display: inline-block; width: auto; margin: 0 6px; }
.hosted-read .r-namebox .r-in { margin: 4px 0 0; }
.hosted-read .r-p p { margin: 0 0 .9em; }
.hosted-read .r-p.fav p { box-shadow: inset 3px 0 0 var(--h-accent); padding-left: 12px; }
.hosted-read .r-mark { font: 14px/1.45 -apple-system, system-ui, sans-serif; color: var(--h-soft); margin: -4px 0 14px; padding: 6px 10px; border-left: 2px solid var(--h-line); }
.hosted-read .r-mark span { color: var(--h-ink); }
.hosted-read .r-cbox { font: 15px -apple-system, system-ui, sans-serif; margin: -4px 0 16px; }
.hosted-read textarea { width: 100%; box-sizing: border-box; font: 16px/1.45 -apple-system, system-ui, sans-serif; padding: 9px 10px; border-radius: 8px; border: 1px solid var(--h-line); background: var(--h-card); color: var(--h-ink); }
.hosted-read .row { display: flex; gap: 10px; align-items: center; }
.hosted-read .linkish { background: none; border: 0; padding: 0; margin: 0; color: var(--h-accent); text-decoration: underline; cursor: pointer; font: inherit; }
.hosted-read .r-note { margin-top: 36px; padding-top: 18px; border-top: 1px solid var(--h-line); }
.r-bar { position: absolute; z-index: 60; display: flex; gap: 4px; padding: 4px; border-radius: 999px; background: var(--h-ink); box-shadow: 0 4px 16px rgba(0, 0, 0, .2); }
.r-bar button { font: 14px -apple-system, system-ui, sans-serif; border: 0; border-radius: 999px; padding: 7px 12px; background: transparent; color: var(--h-card); cursor: pointer; }
.r-bar button:hover { background: rgba(255, 255, 255, .14); }
.r-bar[hidden] { display: none; }
/* Phones and narrow windows (where the centered ask bar reaches the left corner): Account and Share shrink into a
   ~48px strip at the bottom left. The editor keeps its ask bar and panel above a 56px strip (styles.css, app.js hostedStrip). */
@media (max-width: 1080px) {
  .hosted-account-btn { left: 8px; bottom: calc(8px + env(safe-area-inset-bottom)); font-size: 12.5px; padding: 5px 10px; }
  .hosted-share-btn { left: 82px; }
}
/* Account → own-key guide (free beta Workshop is the default). */
.hosted-account details.byok { margin: 6px 0 10px; } .hosted-account details.byok > summary { cursor: pointer; font-size: 14px; }
.hosted-account ol.guide { margin: 8px 0; padding-left: 20px; } .hosted-account ol.guide li { margin: 3px 0; }
/* Reader protections (2026-10-26): Turnstile check card, refusals next to what the reader typed, read-only links.
   Author: Comments off toggle, hidden readers, unverified guest labels. */
.r-check { position: fixed; z-index: 70; left: 50%; bottom: 16px; transform: translateX(-50%); max-width: calc(100vw - 32px); padding: 10px 14px; border-radius: 12px; border: 1px solid var(--h-line); background: var(--h-card); box-shadow: 0 4px 16px rgba(0, 0, 0, .15); }
.r-check p { margin: 0 0 6px; }
.hosted-read .r-err { color: var(--h-danger); margin: 4px 0; } .hosted-read .r-err:empty { display: none; }
.hosted-read .r-closed { padding: 8px 12px; border: 1px solid var(--h-line); border-radius: 8px; background: var(--h-card); }
.hosted-read .r-who .r-in[type=email] { display: inline-block; width: auto; margin: 0 6px; }
.hosted-read .r-namebox .r-in + label { display: block; margin-top: 8px; }
.hosted-share .fb-hidden { opacity: .6; }
.hosted-share .fb-c .row, .hosted-share .fb-pass .row { flex-wrap: wrap; gap: 6px; }
.hosted-share .share-list .row { flex-wrap: wrap; }
