/* The matching app at /app/. Phone first; on a wide screen it stays a phone-width column.
   Look: 留白 (site.css) made softer for the app (2026-11-28): cream paper, a blush wash at the top of every screen,
   peach and clay, round cards, pastel chips, a floating tab bar, small gentle motion. Serif titles and the two
   moons stay. No pink hearts, no glow, nothing that shouts. */

/* The app does not zoom: in the phone app a stray pinch or double-tap left the page enlarged with no way to
   get back. (The website's own pages still zoom normally.) */
html:has(body.app) { touch-action: pan-x pan-y; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; overflow-x: hidden; }
/* clip, not hidden: hidden would make the body its own scroll box, and the sticky top bar and buttons would stop sticking. */
body.app { background: #efe6da; min-height: 100dvh; overflow-x: clip; -webkit-tap-highlight-color: transparent; }
/* iOS enlarges the page when a field with text under 16 px gets focus. */
.app input, .app select, .app textarea { font-size: max(16px, 1em); }
.app { --bg: #fbf6ef; --card: #fffdfa; --hair: #efe3d5; --blush: #f8e6dc; --peach: #e9b49c; --rose: #c47b5c;
  --grad: linear-gradient(135deg, #c47b5c, #9c5a3f); --soft: 0 1px 2px rgba(120, 78, 52, .05), 0 12px 30px rgba(120, 78, 52, .09); }
.app-top, .app-view, .tabbar { width: min(100%, 480px); margin-inline: auto; }
.center { text-align: center; }

/* top bar: the mark on the three main screens, a centred title with a back arrow on the others */
.app-top { position: sticky; top: 0; z-index: 5; display: grid; grid-template-columns: 44px 1fr 44px; align-items: center; min-height: 56px;
  padding: max(6px, env(safe-area-inset-top)) 10px 6px; background: rgba(251, 240, 232, .9); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.app-top h1 { grid-column: 2; font-size: 1.1rem; margin: 0; letter-spacing: .1em; display: flex; align-items: center; justify-content: center; gap: 10px; min-width: 0; }
.app-top h1 img, .app-top h1 .avatar { width: 34px; height: 34px; flex: none; box-shadow: 0 0 0 2px #fff, 0 0 0 3px var(--peach); }
.app-brand { grid-column: 1 / 3; display: flex; align-items: center; gap: 10px; padding-left: 8px; font-family: var(--serif); font-size: 1.15rem; letter-spacing: .14em; }
.app-brand svg { width: 34px; height: 22px; }
.app-brand small { color: var(--muted); letter-spacing: .12em; font-size: .9rem; }
.icon-btn { width: 44px; height: 44px; border: 0; background: none; color: var(--text); cursor: pointer; border-radius: 50%; display: grid; place-items: center; font: inherit; font-size: 1.3rem; }
.icon-btn svg { width: 22px; height: 22px; }
#back { grid-column: 1; grid-row: 1; } #more { grid-column: 3; grid-row: 1; }
body.landing .app-top { display: none; }

/* every screen: cream, with a blush wash coming down from the top */
.app-view { min-height: calc(100dvh - 56px); padding: 10px 18px 128px;
  background: radial-gradient(130% 340px at 50% 0, #fbe9df 0, rgba(251, 233, 223, 0) 100%) no-repeat, var(--bg); }
.app-view > * { animation: rise .36s ease both; }
.app-view > *:nth-child(2) { animation-delay: .04s; } .app-view > *:nth-child(3) { animation-delay: .08s; } .app-view > *:nth-child(n+4) { animation-delay: .12s; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } }
@media (prefers-reduced-motion: reduce) { .app *, .app *::before, .app *::after { animation: none !important; transition: none !important; } }
.page-head { margin: 6px 2px 18px; }
.page-title { font-size: 1.75rem; letter-spacing: .08em; margin: 0; line-height: 1.3; }
.page-sub { color: var(--muted); font-size: .9rem; letter-spacing: .08em; margin: 6px 0 0; }
.steps { display: flex; gap: 6px; margin-top: 12px; }
.steps i { height: 4px; flex: 1; max-width: 46px; border-radius: 4px; background: #ecd9cb; }
.steps i.done { background: var(--peach); } .steps i.now { background: var(--rose); }

/* tab bar: a rounded bar that floats above the page */
.tabbar { position: fixed; bottom: calc(10px + env(safe-area-inset-bottom)); left: 12px; right: 12px; width: min(100% - 24px, 456px); z-index: 5; display: grid; grid-template-columns: repeat(3, 1fr);
  background: rgba(255, 253, 250, .94); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border: 1px solid #f1e3d6; border-radius: 26px; padding: 4px;
  box-shadow: 0 10px 30px rgba(120, 78, 52, .16); box-sizing: border-box; }
.tabbar button { position: relative; min-height: 54px; border: 0; background: none; border-radius: 22px; font: inherit; font-size: .72rem; color: #94887a; letter-spacing: .16em; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; transition: background .2s, color .2s; }
.tabbar svg { width: 23px; height: 23px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.tabbar button[aria-current="true"] { color: var(--accent); background: var(--blush); }
.tabbar button[aria-current="true"] svg .fill { fill: currentColor; fill-opacity: .9; }
.tabbar button[data-badge]::after { content: attr(data-badge); position: absolute; top: 5px; left: calc(50% + 8px); min-width: 18px; height: 18px; padding: 0 5px; box-sizing: border-box;
  border-radius: 999px; background: var(--rose); color: #fff; font-size: .68rem; line-height: 18px; letter-spacing: 0; font-weight: 500; box-shadow: 0 0 0 2px #fffdfa; }

/* buttons inside the app */
.app .btn { min-height: 52px; border: 0; background: var(--grad); box-shadow: 0 8px 20px rgba(156, 90, 63, .22); letter-spacing: .14em; border-radius: 999px; transition: transform .12s; }
.app .btn:active { transform: scale(.97); }
.app .btn.ghost { box-shadow: none; background: #fffdfa; border: 1px solid #ecd9cb; color: var(--accent); }
.app .btn.small { min-height: 44px; box-shadow: none; }
.app .btn[disabled] { box-shadow: none; opacity: .6; }
.btn.has-new { border-color: var(--rose); }
.app .btn.ghost.danger, .danger { color: #8f3a2a; }

/* a person */
.person-card { display: grid; gap: 12px; }
.person-photo-wrap { position: relative; border-radius: 30px; overflow: hidden; box-shadow: var(--soft); background: linear-gradient(165deg, #f6e4d6, #e6c0a8); }
.person-photo { aspect-ratio: 4 / 5; display: block; width: 100%; object-fit: cover; }
.person-photo.empty { position: relative; }
.person-photo.empty::before, .person-photo.empty::after { content: ""; position: absolute; top: 28%; width: 34%; aspect-ratio: 1; border-radius: 50%; }
.person-photo.empty::before { left: 23%; background: #fbf3e6; box-shadow: 0 8px 30px rgba(120, 90, 60, .12); }
.person-photo.empty::after { left: 42%; background: #d29a7c; opacity: .84; }
.person-over { position: absolute; inset: auto 0 0 0; padding: 70px 22px 20px; color: #fffdf8; pointer-events: none;
  background: linear-gradient(to top, rgba(58, 38, 28, .7), rgba(58, 38, 28, .3) 55%, rgba(58, 38, 28, 0)); }
.person-name { font-family: var(--serif); font-size: 1.9rem; letter-spacing: .08em; margin: 0; line-height: 1.2; color: inherit; font-weight: 400; }
.person-name .age { font-size: 1.5rem; letter-spacing: .04em; margin-left: 8px; }
.person-meta { font-size: .9rem; margin: 4px 0 0; letter-spacing: .1em; opacity: .95; }
.person-over .badge, .person-over .badge.ok { border-color: rgba(255, 253, 248, .75); color: #fffdf8; margin-left: 10px; background: rgba(58, 38, 28, .25); letter-spacing: .12em; }
.photo-dots { position: absolute; top: 12px; left: 16px; right: 16px; display: flex; gap: 5px; pointer-events: none; }
.photo-dots i { flex: 1; height: 3px; border-radius: 3px; background: rgba(255, 253, 248, .45); }
.photo-dots i.on { background: #fffdf8; }
.photo-nav { position: absolute; top: 0; bottom: 0; width: 38%; border: 0; background: none; cursor: pointer; padding: 0; }
.photo-nav.prev { left: 0; } .photo-nav.next { right: 0; }
.badge { display: inline-block; font-size: .72rem; border: 1px solid var(--hair); border-radius: 999px; padding: 1px 10px; color: var(--muted); letter-spacing: .08em; vertical-align: middle; font-family: inherit; }
.badge.ok { color: var(--ok); border-color: var(--ok); }
.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tags span { background: #fffdfa; border: 1px solid #f0dfd1; border-radius: 999px; padding: 5px 14px; font-size: .85rem; color: #6b5445; letter-spacing: .04em; }
.tags span:nth-child(3n+1) { background: var(--blush); border-color: #f3d9cb; }
.tags span:nth-child(3n+2) { background: #f3ecdd; border-color: #e9dfca; }
.fit-card, .about-card { background: var(--card); border: 1px solid var(--hair); border-radius: 24px; box-shadow: var(--soft); }
.fit-card { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 4px; padding: 14px 16px; background: linear-gradient(135deg, #fffdfa 40%, #fbece3); }
.fit-num { position: relative; width: 84px; height: 84px; display: grid; place-items: center; text-align: center; }
.fit-num .ring { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.fit-num .ring circle { fill: none; stroke: #f3e0d4; stroke-width: 5; }
.fit-num .ring .v { stroke: var(--rose); stroke-linecap: round; animation: draw .9s ease both; }
@keyframes draw { from { stroke-dasharray: 0 170; } }
.fit-num b { display: block; font-family: var(--serif); font-size: 1.9rem; font-weight: 400; line-height: 1; color: var(--accent); letter-spacing: 0; }
.fit-num span { display: block; font-size: .62rem; color: var(--muted); letter-spacing: .14em; margin-top: 3px; }
.fit-text { padding: 2px 6px 2px 12px; }
.fit-text p { margin: 8px 0 0; font-size: .95rem; line-height: 1.7; }
.chip { display: inline-block; background: var(--blush); color: #8a4f38; border-radius: 999px; padding: 2px 12px; font-size: .75rem; letter-spacing: .1em; }
.about-card { padding: 6px 20px; }
.qa > div { padding: 14px 0; }
.qa > div + div { border-top: 1px dashed #ecdccd; }
.qa p { margin: 0; line-height: 1.75; }
.qa .q { color: var(--rose); font-size: .78rem; letter-spacing: .14em; margin-bottom: 3px; }
.choose { position: sticky; bottom: calc(84px + env(safe-area-inset-bottom)); z-index: 4; display: grid; grid-template-columns: auto 1fr; gap: 12px; margin-top: 18px; align-items: center; }
/* what scrolls under the two buttons fades out, so they never sit on top of text */
.choose::before { content: ""; position: absolute; inset: -22px -18px -100px; z-index: -1; pointer-events: none; background: linear-gradient(rgba(251, 246, 239, 0), var(--bg) 34%); }
.app .choose .btn { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 58px; font-size: 1.05rem; }
.app .choose .btn svg { width: 26px; height: 18px; }
.app .choose .btn.ghost { width: 58px; padding: 0; border-radius: 50%; background: rgba(255, 253, 250, .96); box-shadow: 0 6px 18px rgba(120, 78, 52, .14); color: #8a7a6c; }
.app .choose .btn.ghost svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; }

/* quiet states */
.empty-state { text-align: center; padding: 5vh 12px 0; }
.empty-state img { width: min(64%, 240px); height: auto; aspect-ratio: 1; object-fit: cover; border-radius: 50%; display: block; margin: 0 auto 26px; box-shadow: 0 0 0 8px rgba(255, 253, 250, .7), var(--soft); }
.empty-state h2 { font-size: 1.5rem; letter-spacing: .1em; }
.empty-state p { max-width: 20em; margin-inline: auto; }
.empty-state .btn { margin-top: 12px; }

/* matches */
.fresh { display: flex; gap: 14px; overflow-x: auto; padding: 4px 2px 10px; margin: 0 -18px 8px; padding-inline: 18px; scrollbar-width: none; }
.fresh::-webkit-scrollbar { display: none; }
.fresh button { flex: none; width: 72px; border: 0; background: none; padding: 0; font: inherit; color: var(--text); cursor: pointer; text-align: center; }
.fresh .avatar { width: 66px; height: 66px; margin: 3px auto 6px; box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px var(--peach); }
.fresh span { display: block; font-size: .8rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rows { list-style: none; margin: 0; padding: 4px 14px; background: var(--card); border: 1px solid var(--hair); border-radius: 24px; box-shadow: var(--soft); }
.rows li + li { border-top: 1px solid var(--hair); }
.row { display: grid; grid-template-columns: 56px 1fr auto; gap: 14px; align-items: center; width: 100%; padding: 13px 2px; border: 0; background: none; font: inherit; color: inherit; text-align: left; cursor: pointer; }
.avatar { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; background: linear-gradient(160deg, #f6e4d6, #e2bca4); display: block; }
div.avatar { background: radial-gradient(circle at 61% 50%, rgba(201, 143, 111, .9) 0 24%, transparent 25%), radial-gradient(circle at 40% 50%, #fbf3e6 0 24%, transparent 25%), linear-gradient(160deg, #f6e4d6, #e6c4ad); }
.row b { font-weight: 500; font-size: 1.02rem; letter-spacing: .05em; }
.row .preview { display: block; color: var(--muted); font-size: .88rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-top: 2px; }
.row .side { display: grid; justify-items: end; gap: 6px; align-self: start; padding-top: 4px; }
.row .when { color: #94887a; font-size: .75rem; letter-spacing: .04em; }
.row.unread b, .row.unread .preview { color: var(--text); font-weight: 500; }
.row .count { min-width: 22px; height: 22px; padding: 0 7px; box-sizing: border-box; border-radius: 999px; background: var(--rose); color: #fff; font-size: .75rem; line-height: 22px; text-align: center; }
.section-label { color: #8a7566; font-size: .8rem; letter-spacing: .18em; margin: 22px 4px 10px; }

/* chat */
.chat { display: flex; flex-direction: column; gap: 6px; padding: 6px 0 12px; }
.intro { background: linear-gradient(135deg, #fffdfa 40%, #fbece3); border: 1px solid var(--hair); border-radius: 24px; padding: 18px; margin-bottom: 10px; box-shadow: var(--soft); }
.intro p { margin: 0 0 10px; }
.intro .lead { font-family: var(--serif); font-size: 1.05rem; letter-spacing: .08em; margin-bottom: 6px; }
.intro .lead b { font-size: 1.6rem; font-weight: 400; color: var(--accent); margin-left: 6px; letter-spacing: 0; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips button { border: 1px solid #f1d9cb; background: #fffdfa; border-radius: 999px; padding: 8px 16px; font: inherit; font-size: .88rem; color: #7a4a36; cursor: pointer; min-height: 40px; text-align: left; }
.day { align-self: center; font-size: .72rem; color: #94887a; letter-spacing: .12em; background: rgba(255, 253, 250, .8); border-radius: 999px; padding: 3px 12px; margin: 10px 0 4px; }
.msg-row { display: flex; flex-direction: column; align-items: flex-start; max-width: 80%; align-self: flex-start; animation: rise .22s ease both; }
.msg-row.mine { align-items: flex-end; align-self: flex-end; }
.msg-row .meta { font-size: .68rem; color: #a3968a; letter-spacing: .04em; margin: 2px 6px 0; display: flex; gap: 6px; }
.bubble { max-width: 78%; margin: 0; padding: 10px 16px; border-radius: 22px 22px 22px 8px; background: var(--card); border: 1px solid var(--hair); align-self: flex-start; overflow-wrap: anywhere; white-space: pre-wrap; line-height: 1.65;
  box-shadow: 0 2px 6px rgba(120, 78, 52, .05); }
.msg-row .bubble { max-width: 100%; }
.bubble.mine, .msg-row.mine .bubble { align-self: flex-end; border-radius: 22px 22px 8px 22px; background: var(--grad); border-color: transparent; color: #fffdf8; }
.bubble.big { font-size: 2.6rem; line-height: 1.2; background: none !important; border: 0; box-shadow: none; padding: 2px 4px; }
.bubble.gone, .msg-row.mine .bubble.gone { background: none; border: 1px dashed #dccbbb; color: var(--muted); font-size: .85rem; box-shadow: none; }
.sticker-msg { width: 128px; height: 128px; display: block; }
.photo-msg { position: relative; width: 208px; height: 260px; border: 0; padding: 0; border-radius: 22px; overflow: hidden; background: #efe2d6; cursor: pointer; display: block; box-shadow: var(--soft); }
.photo-msg img { width: 100%; height: 100%; object-fit: cover; display: block; transition: filter .25s; }
.photo-msg.veiled img { filter: blur(22px) saturate(.8); transform: scale(1.15); }
.photo-msg .veil-text { position: absolute; inset: 0; display: grid; place-items: center; color: #fffdf8; font-size: .9rem; letter-spacing: .12em; background: rgba(58, 38, 28, .22); }
.notice { border: 1px solid #efd3bd; color: var(--text); background: #fdf3e8; border-radius: 18px; padding: 12px 16px; font-size: .88rem; line-height: 1.7; }
.composer { position: fixed; bottom: 0; left: 0; right: 0; width: min(100%, 480px); margin-inline: auto; box-sizing: border-box; display: flex; flex-wrap: wrap; align-items: flex-end; gap: 6px;
  padding: 8px 10px calc(8px + env(safe-area-inset-bottom)); background: rgba(255, 251, 246, .96); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-top: 1px solid var(--hair); z-index: 6; }
.composer textarea { flex: 1; min-width: 0; min-height: 44px; max-height: 120px; resize: none; border-radius: 22px; border: 1px solid #ecd9cb; background: var(--card); color: var(--text); font: inherit; padding: 9px 16px; box-sizing: border-box; }
.composer .btn.small { min-height: 44px; padding: 0 20px; }
.composer .tool { width: 44px; height: 44px; flex: none; border: 0; border-radius: 50%; background: none; color: #a06a52; cursor: pointer; display: grid; place-items: center; padding: 0; }
.composer .tool svg { width: 25px; height: 25px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.composer .tool[aria-pressed="true"] { background: var(--blush); color: var(--accent); }
.composer .tool.send { background: var(--grad); color: #fffdf8; box-shadow: 0 6px 14px rgba(156, 90, 63, .22); }
.composer .tool.send svg { width: 21px; height: 21px; fill: currentColor; stroke: none; }
.composer-hint { flex-basis: 100%; margin: 0 6px 2px; font-size: .82rem; color: var(--accent); }
.sticker-panel { flex-basis: 100%; display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; max-height: min(312px, 44dvh); overflow-y: auto; padding: 4px 2px 8px; border-bottom: 1px solid var(--hair); margin-bottom: 4px; }
.sticker-panel[hidden] { display: none; }
.sticker-panel button { border: 0; background: none; padding: 6px; border-radius: 18px; cursor: pointer; aspect-ratio: 1; }
.sticker-panel button:active { background: var(--blush); transform: scale(.94); }
.sticker-panel img { width: 100%; height: 100%; object-fit: contain; display: block; }

/* my profile */
.me-card { display: grid; grid-template-columns: auto 1fr; gap: 16px; align-items: center; background: linear-gradient(135deg, #fffdfa 40%, #fbece3); border: 1px solid var(--hair); border-radius: 24px; box-shadow: var(--soft); padding: 18px; margin-bottom: 14px; }
.me-card .avatar { width: 72px; height: 72px; box-shadow: 0 0 0 3px #fffdfa, 0 0 0 5px var(--peach); }
.me-card h2 { font-size: 1.4rem; letter-spacing: .08em; margin: 0; }
.me-card p { margin: 2px 0 0; color: var(--muted); font-size: .88rem; }
.meter { grid-column: 1 / -1; }
.meter .bar { height: 8px; border-radius: 8px; background: #f3e0d4; overflow: hidden; }
.meter .bar i { display: block; height: 100%; border-radius: 8px; background: var(--grad); transition: width .6s ease; }
.meter p { display: flex; justify-content: space-between; gap: 10px; font-size: .82rem; margin: 8px 0 0; color: #7a6557; }
.photo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 10px; }
.photo-cell { position: relative; aspect-ratio: 4 / 5; border-radius: 18px; overflow: hidden; border: 1px solid var(--hair); background: var(--card); box-shadow: var(--soft); }
.photo-cell img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-cell .tag { position: absolute; left: 6px; bottom: 6px; background: rgba(58, 38, 28, .62); color: #fffdf8; border: 0; border-radius: 999px; padding: 1px 10px; font-size: .7rem; letter-spacing: .1em; }
.photo-cell .x { position: absolute; right: 5px; top: 5px; width: 30px; height: 30px; border-radius: 50%; border: 0; background: rgba(58, 38, 28, .55); color: #fff; font-size: 1rem; cursor: pointer; }
.photo-add { display: grid; place-items: center; color: var(--rose); font-size: 1.8rem; font-weight: 200; cursor: pointer; border: 1.5px dashed #e6c7b5; box-shadow: none; background: rgba(255, 253, 250, .6); }
.app form { gap: 16px; }
.app form input:not([type="checkbox"]), .app form select { border-radius: 16px; border-color: #ecd9cb; background: var(--card); }
/* grouped settings: one soft card, a hairline between rows */
.app form.settings { gap: 0; background: var(--card); border: 1px solid var(--hair); border-radius: 24px; box-shadow: var(--soft); padding: 4px 18px 18px; }
.app form.settings > div, .app form.settings > fieldset { padding: 14px 0; border-bottom: 1px solid var(--hair); margin: 0; }
.app form.settings label, .app form.settings legend { font-size: .78rem; letter-spacing: .14em; color: var(--rose); margin-bottom: 4px; }
.app form.settings input, .app form.settings select { border: 0; background: transparent; padding: 0; min-height: 36px; border-radius: 0; font-size: max(16px, 1.05rem); }
.app form.settings select { margin-left: -4px; }
.app form.settings > .btn { margin-top: 18px; }
.app form.settings > .msg { margin: 8px 0 0; }
.app fieldset.block { border-top: 0; padding-top: 14px; margin-top: 0; }
.app textarea.answer { width: 100%; min-height: 72px; border-radius: 16px; border: 1px solid var(--hair); background: var(--bg); color: var(--text); font: inherit; padding: 10px 14px; margin-top: 6px; box-sizing: border-box; }

/* bottom sheet */
dialog#sheet { border: 0; border-radius: 30px 30px 0 0; padding: 14px 20px calc(20px + env(safe-area-inset-bottom)); width: min(100%, 480px); max-width: none; box-sizing: border-box;
  margin: auto auto 0; background: var(--bg); color: var(--text); box-shadow: 0 -12px 40px rgba(58, 38, 28, .18); max-height: 92dvh; }
dialog#sheet[open] { animation: up .28s ease both; }
@keyframes up { from { transform: translateY(40px); opacity: 0; } }
dialog#sheet::before { content: ""; display: block; width: 40px; height: 4px; border-radius: 2px; background: #e3d0c1; margin: 0 auto 18px; }
dialog#sheet::backdrop { background: rgba(58, 38, 28, .5); }
dialog#sheet h2 { font-size: 1.35rem; letter-spacing: .1em; }
dialog#sheet.celebrate { text-align: center; background: radial-gradient(120% 260px at 50% 0, #fbe4d8, rgba(251, 228, 216, 0)), var(--bg); }
dialog#sheet.celebrate img { width: 150px; height: 150px; border-radius: 50%; object-fit: cover; display: block; margin: 4px auto 18px; box-shadow: 0 0 0 8px rgba(255, 253, 250, .7), var(--soft); animation: pop .5s cubic-bezier(.2, 1.4, .4, 1) both; }
@keyframes pop { from { transform: scale(.7); opacity: 0; } }
dialog#sheet.celebrate h2 { font-size: 1.7rem; }
dialog#sheet.viewer h2 { display: none; }
dialog#sheet.viewer .full { width: 100%; max-height: 66dvh; object-fit: contain; border-radius: 20px; display: block; background: #efe2d6; }
/* placing a new profile photo: drag to move, pinch or the slider to zoom */
.crop { position: relative; aspect-ratio: 4 / 5; width: min(100%, 44dvh); margin: 0 auto; border-radius: 22px; overflow: hidden; background: #efe2d6; touch-action: none; cursor: grab; user-select: none; -webkit-user-select: none; }
.crop:active { cursor: grabbing; }
.crop canvas { width: 100%; height: 100%; display: block; }
/* the round part that is used wherever the first photo is shown as a face */
.crop::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; aspect-ratio: 1; transform: translateY(-50%); border-radius: 50%; border: 1.5px dashed rgba(255, 253, 248, .9); box-shadow: 0 0 0 1px rgba(58, 38, 28, .28); pointer-events: none; }
dialog#sheet.cropper input[type="range"] { width: min(100%, 44dvh); display: block; margin: 16px auto 0; accent-color: var(--rose); min-height: 32px; padding: 0; border: 0; background: none; }
.sheet-actions { display: grid; gap: 10px; margin-top: 18px; }

/* signed out: the welcome screen, then sign in / sign up */
.app-view.welcome { padding: 0; min-height: 100dvh; display: grid; grid-template-rows: 1fr auto; background: #fbf6ef; position: relative; isolation: isolate; }
.welcome-art { position: absolute; inset: 0 0 auto 0; width: 100%; height: 78%; object-fit: cover; object-position: 50% 38%; z-index: -1; animation: none;
  -webkit-mask-image: linear-gradient(#000 62%, transparent); mask-image: linear-gradient(#000 62%, transparent); }
.welcome-body { grid-row: 2; padding: 0 26px calc(34px + env(safe-area-inset-bottom)); text-align: center; }
.welcome-mark { width: 64px; height: 42px; display: block; margin: 0 auto 6px; }
.welcome-name { font-family: var(--serif); letter-spacing: .16em; margin: 0 0 22px; }
.welcome-body h2 { font-size: 1.9rem; letter-spacing: .22em; margin: 0 0 8px; }
.welcome-body .muted { margin-bottom: 28px; letter-spacing: .1em; }
.welcome-body .sheet-actions { margin-top: 0; }
.seg { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; border: 1px solid var(--hair); border-radius: 999px; background: var(--card); margin: 4px 0 22px; }
.seg button { min-height: 44px; border: 0; border-radius: 999px; background: none; font: inherit; color: var(--muted); letter-spacing: .12em; cursor: pointer; }
.seg button.on { background: var(--grad); color: #fffdf8; }
