:root {
  --paper: #f7f2e8;
  --paper-deep: #efe6d6;
  --card: rgba(255, 253, 247, .92);
  --card-solid: #fffdf7;
  --ink: #29332f;
  --ink-soft: #46524d;
  --muted: #7c857f;
  --line: rgba(45, 58, 52, .11);
  --coral: #e4765c;
  --coral-deep: #c75d45;
  --coral-soft: #f9ded5;
  --green: #4d8c80;
  --green-soft: #dcece7;
  --lilac: #7f75b6;
  --lilac-soft: #e8e4f4;
  --gold: #c7913f;
  --danger: #b64a43;
  --shadow: 0 20px 60px rgba(72, 55, 37, .12);
  --shadow-soft: 0 10px 30px rgba(72, 55, 37, .08);
  --radius-xl: 32px;
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 12px;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  font-family: "PingFang SC", "HarmonyOS Sans SC", "Microsoft YaHei", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}
* { box-sizing: border-box; }
html, body { min-height: 100%; }
body {
  margin: 0; min-height: 100dvh;
  background:
    radial-gradient(circle at 8% 2%, rgba(247, 200, 181, .5), transparent 31rem),
    radial-gradient(circle at 96% 14%, rgba(191, 220, 207, .55), transparent 30rem),
    linear-gradient(155deg, #fbf7ef 0%, var(--paper) 47%, #f2ebdf 100%);
  overflow-x: hidden;
}
button, input, textarea, select { font: inherit; }
button { color: inherit; }
button, summary, [role="button"] { -webkit-tap-highlight-color: transparent; }
a { color: var(--coral-deep); }
.is-hidden { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
:focus-visible { outline: 3px solid rgba(77, 140, 128, .45); outline-offset: 3px; }
.ambient { position: fixed; z-index: 0; pointer-events: none; border-radius: 999px; filter: blur(8px); opacity: .6; }
.ambient-a { width: 24rem; height: 24rem; left: -9rem; top: 40vh; background: radial-gradient(circle, rgba(228, 118, 92, .19), transparent 68%); }
.ambient-b { width: 30rem; height: 30rem; right: -14rem; bottom: -8rem; background: radial-gradient(circle, rgba(77, 140, 128, .15), transparent 66%); }
.app-shell { position: relative; z-index: 1; width: min(100%, 760px); min-height: 100dvh; margin: 0 auto; padding: calc(var(--safe-top) + 24px) 20px calc(var(--safe-bottom) + 108px); }
.topbar { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; margin: 0 4px 22px; }
.topbar h1 { margin: 3px 0 0; font-family: "Songti SC", "STSong", "Noto Serif CJK SC", serif; font-size: clamp(2rem, 7vw, 2.65rem); font-weight: 700; letter-spacing: .04em; line-height: 1.05; }
.eyebrow { margin: 0; color: var(--coral-deep); font-size: .78rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; }
.topbar-actions { display: flex; align-items: center; gap: 10px; padding-top: 4px; }
.icon-button { width: 44px; height: 44px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 50%; background: rgba(255, 253, 247, .72); box-shadow: 0 8px 18px rgba(72, 55, 37, .06); cursor: pointer; }
.icon-button svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.connection-pill { display: inline-flex; align-items: center; gap: 7px; min-height: 34px; padding: 7px 11px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); background: rgba(255, 253, 247, .65); font-size: .76rem; white-space: nowrap; }
.connection-pill i { width: 7px; height: 7px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 4px rgba(199,145,63,.12); }
.connection-pill.online i { background: var(--green); box-shadow: 0 0 0 4px rgba(77,140,128,.13); }
.connection-pill.offline i { background: var(--danger); box-shadow: 0 0 0 4px rgba(182,74,67,.11); }
.view { display: grid; gap: 18px; animation: rise .35s ease both; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.card { background: var(--card); border: 1px solid rgba(255,255,255,.75); border-radius: var(--radius-xl); box-shadow: var(--shadow-soft); backdrop-filter: blur(16px); }
.hero-card { position: relative; overflow: hidden; padding: 24px; background: linear-gradient(135deg, rgba(255, 253, 247, .96), rgba(250, 229, 218, .92)); border: 1px solid rgba(255,255,255,.78); border-radius: var(--radius-xl); box-shadow: var(--shadow-soft); }
.hero-card::after { content: ""; position: absolute; width: 180px; height: 180px; right: -55px; top: -75px; border-radius: 50%; border: 1px solid rgba(228,118,92,.2); box-shadow: 0 0 0 24px rgba(228,118,92,.04), 0 0 0 54px rgba(228,118,92,.025); }
.hero-card h2 { margin: 4px 0 8px; font-size: clamp(1.35rem, 4.2vw, 1.75rem); line-height: 1.35; }
.hero-card p { margin: 0; color: var(--ink-soft); line-height: 1.65; font-size: .94rem; max-width: 90%; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 18px; }
.pill { display: inline-flex; align-items: center; gap: 6px; min-height: 30px; padding: 6px 10px; border-radius: 999px; background: rgba(255,255,255,.66); color: var(--ink-soft); font-size: .78rem; }
.pill.green { background: var(--green-soft); color: #326e63; }
.pill.coral { background: var(--coral-soft); color: var(--coral-deep); }
.pill.lilac { background: var(--lilac-soft); color: #625992; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 4px 4px -4px; }
.section-title { margin: 0; font-size: 1.08rem; letter-spacing: .02em; }
.section-kicker { margin: 2px 0 0; color: var(--muted); font-size: .78rem; }
.text-button { border: 0; background: transparent; color: var(--coral-deep); padding: 7px 4px; cursor: pointer; font-size: .86rem; font-weight: 600; }
.text-button.muted { color: var(--muted); }
.text-button.danger { color: var(--danger); }
.map-card { padding: 10px; overflow: hidden; }
.map-shell { position: relative; overflow: hidden; min-height: 310px; border-radius: 25px; background: radial-gradient(circle at 48% 44%, rgba(77,140,128,.16), transparent 31%), linear-gradient(145deg, #e9f0e9, #f5eddf 72%); border: 1px solid rgba(255,255,255,.8); }
#map-canvas { display: block; width: 100%; height: 100%; min-height: 310px; }
.map-empty { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; padding: 30px; color: var(--muted); pointer-events: none; }
.map-empty strong { display: block; color: var(--ink); font-size: 1rem; margin-bottom: 7px; }
.map-empty small { display: block; line-height: 1.6; }
.map-overlay-top { position: absolute; top: 12px; left: 12px; right: 12px; display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; pointer-events: none; }
.map-label { padding: 7px 10px; border-radius: 999px; background: rgba(255,253,247,.8); border: 1px solid rgba(255,255,255,.82); font-size: .74rem; color: var(--ink-soft); backdrop-filter: blur(10px); }
.share-control { pointer-events: auto; display: inline-flex; align-items: center; gap: 10px; padding: 8px 10px 8px 13px; border-radius: 999px; background: rgba(255,253,247,.9); border: 1px solid rgba(255,255,255,.85); box-shadow: 0 8px 24px rgba(72,55,37,.08); font-size: .79rem; }
.switch { position: relative; width: 44px; height: 26px; flex: 0 0 auto; }
.switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.switch span { position: absolute; inset: 0; border-radius: 999px; background: #cbd1cc; transition: .2s ease; }
.switch span::after { content: ""; position: absolute; width: 20px; height: 20px; left: 3px; top: 3px; background: #fff; border-radius: 50%; box-shadow: 0 2px 7px rgba(0,0,0,.16); transition: .2s ease; }
.switch input:checked + span { background: var(--green); }
.switch input:checked + span::after { transform: translateX(18px); }
.switch input:focus-visible + span { outline: 3px solid rgba(77,140,128,.35); outline-offset: 2px; }
.map-tools { position: absolute; left: 12px; right: 12px; bottom: 12px; display: flex; justify-content: space-between; gap: 10px; pointer-events: none; }
.map-chip { pointer-events: auto; border: 1px solid rgba(255,255,255,.8); background: rgba(255,253,247,.85); border-radius: 999px; padding: 8px 11px; color: var(--muted); font-size: .73rem; cursor: pointer; backdrop-filter: blur(10px); }
.map-chip.active { color: var(--green); background: rgba(220,236,231,.94); }.member-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.member-card { padding: 16px; display: grid; grid-template-columns: 42px minmax(0, 1fr); gap: 11px; align-items: start; }
.avatar { width: 42px; height: 42px; border-radius: 15px; display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 1rem; letter-spacing: .02em; box-shadow: inset 0 0 0 1px rgba(255,255,255,.26); }
.avatar.sm { width: 34px; height: 34px; border-radius: 12px; font-size: .82rem; }
.member-name { display: flex; align-items: center; gap: 6px; font-weight: 700; font-size: .93rem; }
.member-name .you { color: var(--coral-deep); font-size: .68rem; font-weight: 700; background: var(--coral-soft); padding: 2px 5px; border-radius: 5px; }
.member-sub { margin-top: 5px; color: var(--muted); font-size: .76rem; line-height: 1.45; min-height: 2.2em; }
.member-distance { margin-top: 7px; color: var(--green); font-size: .78rem; font-weight: 650; }
.member-card.offline .avatar { filter: grayscale(.55); opacity: .72; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); display: inline-block; }
.status-dot.idle { background: #bdc2be; }
.care-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.care-button { border: 1px solid rgba(255,255,255,.82); background: rgba(255,253,247,.78); border-radius: 22px; min-height: 92px; padding: 13px 8px; display: grid; place-items: center; align-content: center; gap: 7px; cursor: pointer; box-shadow: 0 7px 18px rgba(72,55,37,.045); transition: transform .15s ease, background .15s ease; }
.care-button:hover { transform: translateY(-2px); background: #fffdf7; }
.care-button:active { transform: scale(.98); }
.care-emoji { font-size: 1.65rem; line-height: 1; }
.care-label { color: var(--ink-soft); font-size: .79rem; }
.care-button.custom { background: linear-gradient(145deg, rgba(249,222,213,.74), rgba(255,253,247,.9)); }
.feed { display: grid; gap: 2px; padding: 10px 16px; }
.feed-item { display: grid; grid-template-columns: 32px minmax(0, 1fr) auto; gap: 10px; align-items: start; padding: 12px 0; border-bottom: 1px solid var(--line); }
.feed-item:last-child { border-bottom: 0; }
.feed-emoji { width: 32px; height: 32px; border-radius: 11px; background: var(--coral-soft); display: grid; place-items: center; font-size: 1rem; }
.feed-text { font-size: .86rem; color: var(--ink-soft); line-height: 1.55; }
.feed-text strong { color: var(--ink); }
.feed-time { color: var(--muted); font-size: .7rem; padding-top: 3px; white-space: nowrap; }
.journal-list { display: grid; gap: 12px; }
.journal-card { padding: 20px; }
.journal-top { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.journal-author { display: flex; align-items: center; gap: 9px; }
.journal-author-name { font-size: .86rem; font-weight: 700; }
.journal-time { color: var(--muted); font-size: .7rem; margin-top: 2px; }
.mood-chip { display: inline-flex; align-items: center; gap: 5px; padding: 6px 9px; border-radius: 999px; background: var(--lilac-soft); color: #625992; font-size: .74rem; white-space: nowrap; }
.journal-title { margin: 16px 0 7px; font-family: "Songti SC", "STSong", serif; font-size: 1.23rem; line-height: 1.4; }
.journal-body { margin: 0; white-space: pre-wrap; word-break: break-word; color: var(--ink-soft); line-height: 1.72; font-size: .9rem; }
.wish-box { margin-top: 14px; padding: 12px 14px; border-radius: 14px; background: rgba(220,236,231,.56); color: #346d63; font-size: .84rem; line-height: 1.55; }
.wish-box b { display: block; font-size: .7rem; letter-spacing: .08em; margin-bottom: 4px; color: #4d8c80; }
.journal-footer { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 15px; }
.entry-actions { display: flex; gap: 8px; }
.mini-button { border: 1px solid var(--line); background: rgba(255,255,255,.54); border-radius: 9px; padding: 5px 8px; color: var(--muted); font-size: .72rem; cursor: pointer; }
.visibility-badge { color: var(--muted); font-size: .7rem; }
.fab { position: fixed; z-index: 6; right: max(24px, calc((100vw - 760px) / 2 + 24px)); bottom: calc(var(--safe-bottom) + 91px); min-height: 52px; padding: 0 19px; border: 0; border-radius: 999px; background: var(--ink); color: #fff; box-shadow: 0 12px 30px rgba(41,51,47,.22); cursor: pointer; display: inline-flex; align-items: center; gap: 8px; font-weight: 650; font-size: .88rem; }
.fab svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.empty-state { padding: 36px 26px; text-align: center; color: var(--muted); }
.empty-illustration { width: 72px; height: 72px; margin: 0 auto 15px; border-radius: 24px; background: linear-gradient(145deg, var(--coral-soft), #fff8e9); display: grid; place-items: center; font-size: 2rem; }
.empty-state h3 { margin: 0 0 7px; color: var(--ink); font-size: 1rem; }
.empty-state p { margin: 0 auto; max-width: 300px; line-height: 1.65; font-size: .84rem; }
.me-card { padding: 22px; display: flex; align-items: center; gap: 15px; }
.me-card .avatar { width: 58px; height: 58px; border-radius: 20px; font-size: 1.35rem; }
.me-card h2 { margin: 0 0 4px; font-size: 1.17rem; }
.me-card p { margin: 0; color: var(--muted); font-size: .8rem; }
.invite-card { position: relative; overflow: hidden; padding: 22px; background: linear-gradient(135deg, #2f3a35, #44564d); color: #fff; }
.invite-card::after { content: "6"; position: absolute; right: 16px; bottom: -34px; font: 700 120px/1 serif; color: rgba(255,255,255,.06); }
.invite-card h3 { margin: 0 0 7px; font-size: 1rem; }
.invite-card p { margin: 0; color: rgba(255,255,255,.68); font-size: .8rem; line-height: 1.6; }
.invite-row { display: flex; align-items: center; gap: 10px; margin-top: 16px; }
.invite-code { font-size: 1.7rem; letter-spacing: .2em; font-weight: 700; font-variant-numeric: tabular-nums; }
.copy-button { border: 1px solid rgba(255,255,255,.2); background: rgba(255,255,255,.1); color: #fff; border-radius: 999px; padding: 8px 11px; font-size: .74rem; cursor: pointer; }
.settings-card { overflow: hidden; }
.setting-row { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 16px 18px; border-bottom: 1px solid var(--line); }
.setting-row:last-child { border-bottom: 0; }
.setting-row-text strong { display: block; font-size: .88rem; }
.setting-row-text span { display: block; margin-top: 4px; color: var(--muted); font-size: .75rem; line-height: 1.5; }
.setting-row .switch { flex: 0 0 auto; }
.danger-button { border: 1px solid rgba(182,74,67,.18); background: rgba(182,74,67,.06); color: var(--danger); border-radius: 12px; min-height: 42px; padding: 0 14px; cursor: pointer; font-weight: 600; font-size: .8rem; }
.secondary-button { border: 1px solid var(--line); background: rgba(255,255,255,.6); color: var(--ink); border-radius: 14px; min-height: 46px; padding: 0 16px; cursor: pointer; font-weight: 600; font-size: .84rem; }
.bottom-nav { position: fixed; z-index: 5; left: 50%; transform: translateX(-50%); bottom: calc(var(--safe-bottom) + 12px); width: min(calc(100% - 28px), 732px); display: grid; grid-template-columns: repeat(4, 1fr); padding: 7px 8px; border: 1px solid rgba(255,255,255,.86); border-radius: 24px; background: rgba(255,253,247,.88); box-shadow: 0 16px 40px rgba(72,55,37,.16); backdrop-filter: blur(20px); }
.bottom-nav button { border: 0; background: transparent; border-radius: 18px; min-height: 55px; display: grid; place-items: center; align-content: center; gap: 4px; color: var(--muted); font-size: .68rem; cursor: pointer; }
.bottom-nav button.active { background: rgba(228,118,92,.105); color: var(--coral-deep); }
.bottom-nav svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }.auth-screen { position: relative; z-index: 2; min-height: 100dvh; display: grid; place-items: center; padding: calc(var(--safe-top) + 28px) 20px calc(var(--safe-bottom) + 28px); }
.auth-card { width: min(100%, 460px); padding: 34px; border-radius: 36px; background: rgba(255,253,247,.88); border: 1px solid rgba(255,255,255,.9); box-shadow: var(--shadow); backdrop-filter: blur(22px); }
.auth-card.compact-card { max-width: 440px; }
.brand-mark { width: 66px; height: 66px; display: grid; place-items: center; margin-bottom: 22px; border-radius: 23px; background: linear-gradient(145deg, var(--coral), #ef9d80); box-shadow: 0 13px 28px rgba(228,118,92,.24); }
.brand-mark svg { width: 42px; height: 42px; fill: #fff; }
.brand-mark .arc { fill: none; stroke: rgba(255,255,255,.7); stroke-width: 2; stroke-linecap: round; }
.auth-card h1 { margin: 5px 0 12px; font-family: "Songti SC", "STSong", serif; font-size: 3rem; letter-spacing: .08em; }
.auth-lead { margin: 0 0 25px; color: var(--ink-soft); line-height: 1.7; font-size: .91rem; }
.segmented { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; border-radius: 14px; background: rgba(45,58,52,.055); margin-bottom: 18px; }
.segmented button { border: 0; border-radius: 11px; min-height: 38px; background: transparent; color: var(--muted); cursor: pointer; font-size: .84rem; font-weight: 600; }
.segmented button.active { background: #fffdf7; color: var(--ink); box-shadow: 0 4px 12px rgba(72,55,37,.08); }
.stack { display: grid; gap: 13px; }
.field { display: grid; gap: 7px; }
.field > span { color: var(--ink-soft); font-size: .77rem; font-weight: 650; }
.field input, .field textarea, .field select { width: 100%; border: 1px solid rgba(45,58,52,.13); border-radius: 14px; background: rgba(255,255,255,.66); color: var(--ink); padding: 13px 14px; font-size: .9rem; outline: none; transition: border .15s ease, box-shadow .15s ease; }
.field input:focus, .field textarea:focus, .field select:focus { border-color: rgba(77,140,128,.6); box-shadow: 0 0 0 4px rgba(77,140,128,.1); }
.field textarea { min-height: 105px; resize: vertical; line-height: 1.6; }
.field.compact input { padding: 10px 12px; font-size: .82rem; }
.primary-button { width: 100%; min-height: 50px; border: 0; border-radius: 15px; cursor: pointer; background: var(--ink); color: #fff; font-weight: 700; letter-spacing: .02em; font-size: .9rem; box-shadow: 0 10px 22px rgba(41,51,47,.18); }
.primary-button:disabled { opacity: .55; cursor: progress; }
.form-error { min-height: 1.2em; margin: 0; color: var(--danger); font-size: .77rem; line-height: 1.45; }
.server-settings { margin-top: 17px; border-top: 1px solid var(--line); padding-top: 14px; }
.server-settings summary { color: var(--muted); font-size: .76rem; cursor: pointer; }
.server-settings .field { margin-top: 12px; }
.server-settings p { color: var(--muted); font-size: .71rem; line-height: 1.55; margin: 8px 0 0; }
.privacy-note { margin: 17px 0 0; color: var(--muted); font-size: .71rem; line-height: 1.62; }
.or-divider { display: flex; align-items: center; gap: 10px; margin: 19px 0; color: var(--muted); font-size: .72rem; }
.or-divider::before, .or-divider::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.register-only.is-hidden { display: none !important; }
.sheet-root { position: fixed; inset: 0; z-index: 30; display: grid; align-items: end; justify-items: center; padding: 20px; padding-bottom: calc(var(--safe-bottom) + 16px); }
.sheet-backdrop { position: absolute; inset: 0; background: rgba(26,34,30,.36); backdrop-filter: blur(3px); animation: fade .2s ease both; }
@keyframes fade { from { opacity: 0; } }
.sheet-panel { position: relative; width: min(100%, 620px); max-height: min(88dvh, 760px); overflow: auto; border-radius: 28px; background: var(--card-solid); border: 1px solid rgba(255,255,255,.9); box-shadow: 0 30px 80px rgba(28,36,32,.24); padding: 22px; animation: sheet-up .24s cubic-bezier(.2,.72,.3,1) both; }
@keyframes sheet-up { from { transform: translateY(24px); opacity: .4; } to { transform: none; opacity: 1; } }
.sheet-grabber { width: 40px; height: 4px; border-radius: 999px; background: rgba(45,58,52,.16); margin: 0 auto 16px; }
.sheet-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 15px; margin-bottom: 18px; }
.sheet-head h2 { margin: 0; font-size: 1.25rem; }
.sheet-head p { margin: 5px 0 0; color: var(--muted); font-size: .78rem; line-height: 1.5; }
.close-button { border: 0; background: rgba(45,58,52,.06); border-radius: 50%; width: 34px; height: 34px; cursor: pointer; display: grid; place-items: center; font-size: 1.05rem; }
.mood-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.mood-option { border: 1px solid var(--line); border-radius: 12px; min-height: 42px; background: rgba(255,255,255,.62); color: var(--ink-soft); cursor: pointer; font-size: .8rem; }
.mood-option.active { background: var(--lilac-soft); border-color: rgba(127,117,182,.3); color: #625992; font-weight: 650; }
.form-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 18px; }
.form-actions .primary-button { width: auto; min-width: 128px; padding: 0 20px; }
.privacy-choice { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.privacy-choice button { border: 1px solid var(--line); border-radius: 12px; min-height: 44px; background: rgba(255,255,255,.62); cursor: pointer; color: var(--muted); font-size: .78rem; }
.privacy-choice button.active { border-color: rgba(77,140,128,.3); background: var(--green-soft); color: #326e63; font-weight: 650; }
.toast { position: fixed; z-index: 50; left: 50%; bottom: calc(var(--safe-bottom) + 86px); transform: translate(-50%, 20px); opacity: 0; pointer-events: none; max-width: min(90vw, 460px); padding: 11px 16px; border-radius: 14px; background: rgba(41,51,47,.93); color: #fff; font-size: .8rem; line-height: 1.45; box-shadow: 0 10px 30px rgba(28,36,32,.22); transition: .22s ease; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.startup { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; align-content: center; gap: 16px; background: var(--paper); transition: opacity .3s ease; }
.startup.done { opacity: 0; pointer-events: none; }
.startup-mark { width: 62px; height: 62px; border-radius: 22px; display: grid; place-items: center; background: var(--coral); color: #fff; font: 700 1.7rem/1 "Songti SC", serif; box-shadow: 0 12px 30px rgba(228,118,92,.25); animation: breathe 1.7s ease-in-out infinite; }
.startup p { margin: 0; color: var(--muted); font-size: .78rem; }
@keyframes breathe { 50% { transform: scale(1.05); } }
@media (min-width: 760px) {
  body::before { content: ""; position: fixed; inset: 0; pointer-events: none; background: linear-gradient(90deg, rgba(41,51,47,.025) 1px, transparent 1px), linear-gradient(rgba(41,51,47,.025) 1px, transparent 1px); background-size: 32px 32px; mask-image: linear-gradient(to bottom, #000, transparent 80%); }
  .app-shell { padding-left: 26px; padding-right: 26px; }
}
@media (max-width: 520px) {
  .app-shell { padding-left: 15px; padding-right: 15px; }
  .topbar { margin-bottom: 18px; }
  .topbar h1 { font-size: 2rem; }
  .connection-pill span { display: none; }
  .connection-pill { width: 34px; justify-content: center; padding: 0; }
  .hero-card { padding: 21px; }
  .member-grid { grid-template-columns: 1fr; }
  .auth-card { padding: 27px 22px; border-radius: 30px; }
  .auth-card h1 { font-size: 2.65rem; }
  .care-grid { gap: 8px; }
  .care-button { min-height: 84px; }
  .journal-card { padding: 18px; }
  .fab { right: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; transition-duration: .01ms !important; }
}
/* Real map */
.amap-map {
  position: absolute;
  inset: 0;
  z-index: 0;
  opacity: 0;
  pointer-events: none;
  background: #e7eee9;
}
.map-shell.real-map .amap-map { opacity: 1; pointer-events: auto; }
.map-shell.real-map #map-canvas { display: none; }
.map-shell.real-map { background: #e7eee9; }
.map-overlay-top { z-index: 4; }
.map-tools { z-index: 4; align-items: flex-end; }
.map-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; pointer-events: auto; }
.map-actions .map-chip { white-space: nowrap; }
.real-map-empty {
  position: absolute; z-index: 3; left: 50%; top: 50%; transform: translate(-50%, -50%);
  display: grid; gap: 6px; width: min(260px, 78%); padding: 15px 17px; text-align: center;
  border: 1px solid rgba(255,255,255,.9); border-radius: 16px;
  background: rgba(255,253,247,.92); box-shadow: 0 10px 30px rgba(28,36,32,.12);
  pointer-events: none; backdrop-filter: blur(12px);
}
.real-map-empty strong { font-size: .88rem; }
.real-map-empty span { color: var(--muted); font-size: .74rem; line-height: 1.5; }
.amap-person {
  position: relative; width: 34px; height: 34px; cursor: pointer; user-select: none;
}
.amap-avatar {
  width: 34px; height: 34px; display: grid; place-items: center;
  border: 3px solid #fffdf7; border-radius: 50%; color: #fff;
  font-size: .8rem; font-weight: 700; box-shadow: 0 5px 16px rgba(30,43,38,.24);
}
.amap-person.me .amap-avatar { box-shadow: 0 0 0 5px rgba(228,118,92,.16), 0 6px 18px rgba(30,43,38,.22); }
.amap-name {
  position: absolute; top: 36px; left: 50%; transform: translateX(-50%);
  max-width: 96px; padding: 3px 7px; border-radius: 999px; color: var(--ink);
  background: rgba(255,253,247,.94); box-shadow: 0 3px 10px rgba(30,43,38,.12);
  font-size: .68rem; line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.amap-info { padding: 3px 4px; min-width: 180px; max-width: 280px; color: var(--ink); }
.amap-info strong { display: block; font-size: .9rem; }
.amap-info p { margin: 6px 0 3px; color: var(--ink-soft); font-size: .8rem; line-height: 1.5; }
.amap-info span { display: block; color: var(--muted); font-size: .7rem; line-height: 1.5; }
.amap-info small { display: block; margin-top: 5px; color: var(--muted); font-size: .66rem; }
.amap-info-window { border-radius: 14px !important; }
.member-precision { margin-top: 5px; width: fit-content; padding: 2px 6px; border-radius: 5px; font-size: .68rem; font-weight: 650; background: var(--green-soft); color: #326e63; }
.member-precision.medium { background: #f7edd7; color: #8d6626; }
.member-precision.low { background: var(--coral-soft); color: var(--coral-deep); }
.member-place { margin-top: 5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-soft); font-size: .73rem; line-height: 1.45; }
.member-place:empty { display: none; }
@media (max-width: 520px) {
  .map-actions { max-width: 195px; }
  .map-actions .map-chip { padding: 7px 9px; font-size: .68rem; }
  .map-tools .map-label { max-width: 135px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
}

/* Care targeting, notifications and motion polish */
.nav-badge { position: absolute; top: 4px; right: 16px; min-width: 17px; height: 17px; padding: 0 4px; display: grid; place-items: center; border-radius: 999px; background: var(--coral); color: #fff; font-size: .62rem; font-weight: 800; line-height: 1; box-shadow: 0 4px 10px rgba(228,118,92,.3); }
.nav-badge.pulse { animation: badge-pop .62s cubic-bezier(.2,.8,.25,1); }
@keyframes badge-pop { 0% { transform: scale(.6); } 45% { transform: scale(1.35) rotate(5deg); } 100% { transform: scale(1); } }
.bottom-nav button { position: relative; overflow: hidden; transition: color .22s ease, background .22s ease, transform .18s ease; }
.bottom-nav button.active svg { animation: nav-icon-breathe .5s cubic-bezier(.2,.75,.3,1); }
@keyframes nav-icon-breathe { 0% { transform: translateY(2px) scale(.88); } 55% { transform: translateY(-2px) scale(1.1); } 100% { transform: none; } }

.view.motion-rise { animation: page-rise .48s cubic-bezier(.18,.72,.24,1) both; }
.view.motion-slide { animation: page-slide .46s cubic-bezier(.18,.72,.24,1) both; }
.view.motion-bloom { animation: page-bloom .5s cubic-bezier(.18,.72,.24,1) both; }
.view.motion-tilt { animation: page-tilt .44s cubic-bezier(.18,.72,.24,1) both; }
.view.motion-still { animation: none; }
@keyframes page-rise { from { opacity: 0; transform: translate3d(0, 16px, 0); } to { opacity: 1; transform: none; } }
@keyframes page-slide { from { opacity: 0; transform: translate3d(22px, 3px, 0) scale(.992); } to { opacity: 1; transform: none; } }
@keyframes page-bloom { from { opacity: 0; transform: scale(.974); filter: blur(2px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes page-tilt { from { opacity: 0; transform: translate3d(-12px, 8px, 0) rotate(-.35deg); } to { opacity: 1; transform: none; } }

.reveal-item { opacity: 0; transition: opacity .44s ease, transform .55s cubic-bezier(.17,.72,.24,1); transition-delay: var(--reveal-delay, 0ms); will-change: opacity, transform; }
.reveal-item.reveal-a { transform: translate3d(0, 18px, 0); }
.reveal-item.reveal-b { transform: translate3d(16px, 8px, 0) scale(.99); }
.reveal-item.reveal-c { transform: translate3d(-12px, 9px, 0); }
.reveal-item.reveal-d { transform: scale(.97); }
.reveal-item.is-visible { opacity: 1; transform: none; }

.care-button, .primary-button, .secondary-button, .care-all-button, .recipient-chip, .notify-chip, .map-chip, .bottom-nav button { position: relative; overflow: hidden; }
.tap-ripple { position: absolute; pointer-events: none; border-radius: 50%; background: radial-gradient(circle, rgba(255,255,255,.7), rgba(255,255,255,0) 66%); transform: scale(.2); opacity: .55; animation: tap-ripple .52s ease-out forwards; }
@keyframes tap-ripple { to { transform: scale(1); opacity: 0; } }

.care-target-box { display: grid; gap: 11px; padding: 15px; border-radius: 20px; border: 1px solid rgba(45,58,52,.085); background: linear-gradient(135deg, rgba(255,253,247,.92), rgba(250,239,231,.76)); }
.care-target-box.compact { margin: -4px 4px 2px; padding: 13px 14px; background: rgba(255,253,247,.68); }
.care-target-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.care-target-head strong { display: block; font-size: .84rem; }
.care-target-head span { display: block; margin-top: 3px; color: var(--muted); font-size: .7rem; line-height: 1.45; }
.recipient-selector { display: flex; gap: 8px; overflow-x: auto; padding: 2px 1px 5px; scrollbar-width: none; }
.recipient-selector::-webkit-scrollbar { display: none; }
.recipient-chip { flex: 0 0 auto; min-height: 42px; padding: 7px 11px 7px 8px; display: inline-flex; align-items: center; gap: 7px; border: 1px solid rgba(45,58,52,.1); border-radius: 999px; background: rgba(255,255,255,.68); color: var(--ink-soft); font-size: .76rem; cursor: pointer; transition: transform .18s ease, border-color .18s ease, background .18s ease, box-shadow .18s ease; }
.recipient-chip:hover { transform: translateY(-1px); background: #fffdf7; }
.recipient-chip:active { transform: scale(.96); }
.recipient-chip.active { border-color: rgba(228,118,92,.32); background: var(--coral-soft); color: var(--coral-deep); box-shadow: 0 6px 16px rgba(228,118,92,.12); }
.recipient-chip.just-selected { animation: chip-selected .34s cubic-bezier(.2,.8,.25,1); }
@keyframes chip-selected { 50% { transform: scale(1.07) rotate(-1deg); } }
.recipient-heart { width: 27px; height: 27px; display: grid; place-items: center; border-radius: 50%; background: linear-gradient(145deg, #f6b4a3, var(--coral)); color: #fff; font-size: .82rem; }
.recipient-avatar { width: 27px; height: 27px; display: grid; place-items: center; border-radius: 10px; color: #fff; font-size: .72rem; font-weight: 700; box-shadow: inset 0 0 0 1px rgba(255,255,255,.25); }
.care-target-summary { margin: 0; color: var(--muted); font-size: .73rem; }
.care-target-summary strong { color: var(--ink); }
.care-target-summary.target-changed { animation: target-glow .45s ease; }
@keyframes target-glow { 40% { transform: translateX(3px); color: var(--coral-deep); } }

.care-compose-card { padding: 18px; display: grid; gap: 15px; }
.care-compose-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.care-compose-head h2 { margin: 0; font-size: 1.08rem; }
.care-compose-head p { margin: 4px 0 0; color: var(--muted); font-size: .74rem; line-height: 1.5; }
.notify-chip { flex: 0 0 auto; border: 1px solid var(--line); border-radius: 999px; min-height: 36px; padding: 0 10px; display: inline-flex; align-items: center; gap: 6px; background: rgba(255,255,255,.66); color: var(--muted); font-size: .7rem; cursor: pointer; }
.notify-chip.active { background: var(--green-soft); color: #326e63; border-color: rgba(77,140,128,.22); }
.notify-bell { font-size: .92rem; }
.care-all-button { width: 100%; min-height: 62px; padding: 10px 14px; border: 0; border-radius: 18px; display: grid; grid-template-columns: 38px minmax(0,1fr) auto; align-items: center; gap: 11px; text-align: left; background: linear-gradient(135deg, #2f3a35, #4a6156); color: #fff; box-shadow: 0 12px 26px rgba(41,51,47,.2); cursor: pointer; transition: transform .2s ease, box-shadow .2s ease; }
.care-all-button:hover { transform: translateY(-2px); box-shadow: 0 16px 30px rgba(41,51,47,.24); }
.care-all-button:active { transform: scale(.985); }
.care-all-button:disabled { opacity: .45; cursor: not-allowed; transform: none; }
.care-all-icon { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 13px; background: rgba(255,255,255,.13); color: #ffc8bb; font-size: 1.05rem; }
.care-all-button strong, .care-all-button small { display: block; }
.care-all-button strong { font-size: .86rem; }
.care-all-button small { margin-top: 2px; color: rgba(255,255,255,.66); font-size: .68rem; }
.care-all-arrow { color: rgba(255,255,255,.72); }

.care-group { display: grid; gap: 10px; }
.care-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.quick-care-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.care-button { position: relative; overflow: hidden; min-height: 88px; border-color: color-mix(in srgb, var(--care-accent, var(--coral)) 12%, transparent); background: linear-gradient(145deg, color-mix(in srgb, var(--care-accent, var(--coral)) 7%, #fffdf7), rgba(255,253,247,.9)); }
.care-button::after { content: ""; position: absolute; inset: auto -20% -60% 25%; height: 65%; background: radial-gradient(circle, color-mix(in srgb, var(--care-accent, var(--coral)) 20%, transparent), transparent 68%); opacity: .7; pointer-events: none; transition: transform .25s ease, opacity .25s ease; }
.care-button:hover::after { transform: translateY(-8px) scale(1.1); opacity: 1; }
.care-button:hover { transform: translateY(-3px) rotate(-.25deg); }
.care-button:active { transform: scale(.96) rotate(.2deg); }
.care-button:disabled { opacity: .45; cursor: not-allowed; transform: none; }
.care-button.is-sending .care-emoji { animation: care-sending .55s ease infinite alternate; }
@keyframes care-sending { to { transform: translateY(-3px) rotate(6deg) scale(1.08); } }
.care-emoji { position: relative; z-index: 1; filter: drop-shadow(0 4px 6px rgba(72,55,37,.1)); }
.care-label { position: relative; z-index: 1; }
.care-button.care-tone-1 { animation-delay: var(--pop-delay); }
.care-button.care-tone-2 { animation-delay: var(--pop-delay); }
.care-button.care-tone-3 { animation-delay: var(--pop-delay); }
.care-custom-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 16px 18px; border: 1px solid rgba(255,255,255,.8); border-radius: 22px; background: rgba(255,253,247,.72); box-shadow: var(--shadow-soft); }
.care-custom-row > div { min-width: 0; }
.care-custom-row strong { display: block; font-size: .86rem; }
.care-custom-row span { display: block; margin-top: 3px; color: var(--muted); font-size: .72rem; }
.care-custom-row .care-button { flex: 0 0 108px; min-height: 76px; }

.feed-audience { display: block; width: fit-content; margin-top: 5px; padding: 2px 6px; border-radius: 5px; background: var(--green-soft); color: #397268; font-size: .64rem; }
.care-feed-item.unread { position: relative; }
.care-feed-item.unread::before { content: ""; position: absolute; left: -9px; top: 19px; width: 5px; height: 5px; border-radius: 50%; background: var(--coral); box-shadow: 0 0 0 4px rgba(228,118,92,.1); }
.care-feed-item .feed-emoji { background: color-mix(in srgb, var(--care-accent, var(--coral)) 14%, #fffdf7); animation: feed-emoji-in .42s cubic-bezier(.2,.8,.25,1); }
@keyframes feed-emoji-in { from { transform: scale(.6) rotate(-12deg); opacity: .2; } }

.care-burst { position: fixed; z-index: 70; width: 1px; height: 1px; pointer-events: none; }
.care-burst span { position: absolute; left: 0; top: 0; color: var(--coral); font-size: 1rem; font-weight: 800; opacity: 0; animation: care-particle .82s cubic-bezier(.15,.7,.25,1) forwards; }
@keyframes care-particle { 0% { opacity: 0; transform: translate(0, 0) scale(.55) rotate(0); } 18% { opacity: 1; } 100% { opacity: 0; transform: translate(var(--dx), var(--dy)) scale(1.12) rotate(var(--rot)); } }
.care-notice { position: fixed; z-index: 65; top: calc(var(--safe-top) + 12px); left: 50%; width: min(calc(100% - 24px), 520px); transform: translate(-50%, -18px) scale(.97); opacity: 0; pointer-events: none; display: grid; grid-template-columns: 42px minmax(0,1fr) 28px; gap: 10px; align-items: center; padding: 11px 12px; border-radius: 19px; background: rgba(255,253,247,.96); border: 1px solid rgba(255,255,255,.9); box-shadow: 0 18px 48px rgba(28,36,32,.2); backdrop-filter: blur(20px); transition: opacity .28s ease, transform .36s cubic-bezier(.2,.75,.25,1); }
.care-notice.show { opacity: 1; pointer-events: auto; transform: translate(-50%, 0) scale(1); }
.care-notice-emoji { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 14px; background: var(--coral-soft); font-size: 1.2rem; }
.care-notice strong { font-size: .82rem; }
.care-notice p { margin: 3px 0 0; color: var(--muted); font-size: .72rem; line-height: 1.4; }
.care-notice button { border: 0; background: rgba(45,58,52,.06); border-radius: 50%; width: 28px; height: 28px; cursor: pointer; color: var(--muted); }

.sheet-target-line { padding: 12px 14px; border-radius: 14px; background: var(--green-soft); color: #326e63; font-size: .78rem; }
.sheet-target-line strong { color: #24564f; }

@media (max-width: 520px) {
  .care-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .care-compose-head { display: grid; }
  .notify-chip { width: fit-content; }
  .care-button { min-height: 80px; }
  .care-custom-row { align-items: stretch; }
  .care-custom-row .care-button { flex-basis: 96px; }
  .care-notice { top: calc(var(--safe-top) + 8px); }
}

