:root {
    --sona-coral: #FF5F4A;
    --sona-coral-deep: #E9434E;
    --sona-peach: #FF8A72;
    --sona-surface: #FFF2EE;
    --sona-surface-strong: #FFE3DB;
    --sona-line: #FFD5CC;
    --sona-ink: #2C1E26;
    --sona-coral-rgb: 255, 95, 74;
}

* { box-sizing: border-box; }
body {
    font-family: -apple-system, BlinkMacSystemFont, "PingFang TC", "Microsoft JhengHei", sans-serif;
    margin: 0;
    background: #FFF8F5;
    color: var(--sona-ink);
    /* 56px 是底部分頁列的高度（見 .tabbar）——真的比一個螢幕還長、要捲到底的
       頁面才用得到這段，不然最後一段會被固定在底部的分頁列蓋住。桌面版（見
       900px 那個 media query）沒有底部分頁列，改回 0。 */
    padding-bottom: 56px;
}
/* min-height 扣掉分頁列高度，不然頁面內容剛好等於一個螢幕高度時，最後一段
   也會被蓋住——跟上面 body 的 padding-bottom 要一起加才夠，只加一個在某一種
   頁面長度下還是會被蓋到。 */
.shell { max-width: 480px; margin: 0 auto; min-height: calc(100vh - 56px); background: #fff; display: flex; flex-direction: column; }
header.top {
    padding: 14px 16px;
    border-bottom: 1px solid var(--sona-line);
    display: flex;
    align-items: center;
    gap: 10px;
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 5;
}
header.top a.back { text-decoration: none; color: #333; font-size: 20px; }
header.top h1 { font-size: 17px; margin: 0; flex: 1; text-align: center; }
.header-actions { display: flex; align-items: center; gap: 4px; }

.tabs { display: flex; gap: 8px; padding: 12px 16px; }
.tabs a {
    flex: 1;
    text-align: center;
    padding: 10px 0;
    border-radius: 20px;
    background: #FFF0EB;
    color: #333;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
}
.tabs a.active { background: var(--sona-coral-deep); color: #fff; }

.catalog-list { padding: 0 16px 24px; display: flex; flex-direction: column; gap: 12px; }
.char-card {
    display: flex;
    gap: 14px;
    padding: 14px;
    border-radius: 16px;
    background: #FFF9F7;
    text-decoration: none;
    color: inherit;
}
.char-avatar {
    width: 56px; height: 56px; border-radius: 50%;
    background: var(--sona-surface-strong); display: flex; align-items: center; justify-content: center;
    font-size: 24px; color: var(--sona-coral); flex-shrink: 0;
}
.char-avatar.female { background: var(--sona-surface-strong); color: var(--sona-coral-deep); }
.char-name { font-weight: 700; font-size: 16px; }
.char-tags { margin: 4px 0; }
.char-tags span { display: inline-block; background: #FFF0EB; border-radius: 10px; padding: 2px 8px; font-size: 11px; margin-right: 4px; color: #765D63; }
.char-bio { font-size: 13px; color: #777; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.detail-avatar { width: 120px; height: 120px; border-radius: 50%; margin: 24px auto 12px; display: flex; align-items: center; justify-content: center; font-size: 48px; background: var(--sona-surface-strong); color: var(--sona-coral); }
.detail-avatar.female { background: var(--sona-surface-strong); color: var(--sona-coral-deep); }
.detail-name { text-align: center; font-size: 22px; font-weight: 700; }
.detail-tagline { text-align: center; color: #999; margin-bottom: 12px; }
.detail-tags { text-align: center; margin-bottom: 16px; }
.detail-tags span { display: inline-block; background: #FFF0EB; border-radius: 12px; padding: 4px 10px; font-size: 12px; margin: 0 3px; color: #765D63; }
.detail-bio { padding: 0 20px; font-size: 14px; line-height: 1.7; color: #444; white-space: pre-wrap; }
.detail-actions { padding: 20px; margin-top: auto; }
.btn-primary {
    display: block; width: 100%; text-align: center; padding: 14px;
    background: var(--sona-coral-deep); color: #fff; border: none; border-radius: 24px;
    font-size: 16px; font-weight: 600; text-decoration: none; cursor: pointer;
}

/* 手機版輸入框固定在底部分頁列正上方（2026-08-07 使用者回報輸入框會被
   分頁列擋住一半），所以這裡多留一段 padding-bottom 讓最後一則訊息不會
   被固定定位的 .composer 蓋住——高度抓 .composer 實際大約的高度（64px）
   加上它離螢幕底部的偏移（56px 分頁列＋安全區），抓寬一點當緩衝。桌面版
   （見 900px 那個 media query）沒有這個問題，改回原本的 padding。 */
.messages { flex: 1; overflow-y: auto; padding: 16px 16px calc(128px + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; gap: 10px; }
.bubble { max-width: 75%; padding: 10px 14px; border-radius: 16px; font-size: 15px; line-height: 1.5; }
.bubble.user { align-self: flex-end; background: var(--sona-coral-deep); color: #fff; }
.bubble.assistant { align-self: flex-start; background: #FFF0EB; color: var(--sona-ink); }
.typing { align-self: flex-start; color: #999; font-size: 13px; padding: 0 14px; }

/* 輸入框固定在分頁列（.tabbar，高度約56px）正上方，不會隨聊天內容捲動，
   使用者不用捲到底才找得到輸入框。z-index 刻意比 .call-overlay（20）低，
   通話中輸入框會被通話覆蓋層自然蓋住，不會浮在通話畫面上面。 */
.composer {
    display: flex; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--sona-line);
    background: #fff;
    position: fixed; left: 0; right: 0;
    bottom: calc(56px + env(safe-area-inset-bottom, 0px));
    max-width: 480px; margin: 0 auto; z-index: 15;
}
.composer input {
    /* font-size 16px 是刻意的，不是隨便選的數字——iOS Safari 只要 input 的
       font-size 小於 16px，點下去就會自動放大整個畫面（方便使用者看清楚打字
       內容），這正是使用者回報「點輸入框畫面突然變大」的成因。 */
    flex: 1; border: none; background: #FFF5F1; border-radius: 20px; padding: 10px 16px; font-size: 16px;
}
.composer button {
    border: none; background: var(--sona-coral-deep); color: #fff; width: 40px; height: 40px; border-radius: 50%;
    font-size: 18px; cursor: pointer;
}
.composer button:disabled { background: #ccc; }
.error-banner { background: #fde3e3; color: #c0392b; padding: 8px 16px; font-size: 13px; }

.wa-nav-link { align-self: center; color: var(--sona-coral-deep); text-decoration: none; font-size: 13px; font-weight: 600; }

.wa-panel { padding: 20px; max-width: 420px; }
.wa-hint { color: #777; font-size: 13px; margin: 0 0 12px; }
.wa-label { display: block; margin: 16px 0 8px; font-size: 13px; color: #666; font-weight: 600; }
.wa-panel input[type="tel"],
.wa-panel input[type="text"],
.wa-panel input[type="email"],
.wa-panel input[type="password"],
.wa-panel select {
    /* 同 .composer input，16px 是避免 iOS Safari 自動放大畫面的門檻，不能改小。 */
    width: 100%; border: 1px solid #ddd; background: #fafafa; border-radius: 12px;
    padding: 12px 14px; font-size: 16px; box-sizing: border-box; margin-bottom: 10px;
}
.wa-panel .btn-primary { margin-top: 16px; }
.btn-secondary {
    display: block; width: 100%; text-align: center; padding: 12px;
    background: none; color: #888; border: none; border-radius: 24px;
    font-size: 14px; margin-top: 8px; cursor: pointer;
}
.btn-danger { background: #d64545; }

/* ============================================================
   電腦版側邊欄佈局（>=900px）。手機版：.sidebar 預設 display:none，
   .main-panel 只是原本 .shell 內容的包裝殼，flex 屬性讓內部排版
   跟改版前完全一樣，手機版視覺不受任何影響。
   ============================================================ */
.sidebar { display: none; }
.main-panel { flex: 1; min-width: 0; display: flex; flex-direction: column; position: relative; }

@media (min-width: 900px) {
    /* 桌面版用側邊欄導覽，沒有底部分頁列，改回原本沒扣高度的版本。 */
    body { background: #FFF3EF; padding-bottom: 0; }
    .shell { min-height: 100vh; }

    .shell {
        max-width: 1100px;
        flex-direction: row;
        box-shadow: 0 0 40px rgba(0, 0, 0, 0.06);
    }

    .sidebar {
        display: flex;
        flex-direction: column;
        width: 280px;
        flex-shrink: 0;
        border-right: 1px solid var(--sona-line);
        background: #FFF9F7;
    }
    .sidebar-footer { padding: 12px 20px; border-top: 1px solid #eee; display: flex; flex-direction: column; gap: 8px; }
    .sidebar-footer a { color: var(--sona-coral-deep); text-decoration: none; font-size: 13px; font-weight: 600; }
    .sidebar-header { padding: 20px 20px 12px; }
    .sidebar-header h2 { margin: 0 0 12px; font-size: 18px; }
    .sidebar-tabs { display: flex; gap: 8px; }
    .sidebar-tabs button {
        flex: 1; border: none; background: #eee; color: #333; cursor: pointer;
        padding: 8px 0; border-radius: 16px; font-size: 13px; font-weight: 600;
    }
    .sidebar-tabs button.active { background: var(--sona-coral-deep); color: #fff; }
    .sidebar-list { flex: 1; overflow-y: auto; padding: 4px 12px 20px; }
    .sidebar-item {
        display: flex; align-items: center; gap: 10px;
        padding: 8px 10px; border-radius: 10px; text-decoration: none; color: inherit;
    }
    .sidebar-item:hover { background: #f0f0f0; }
    .sidebar-item.active { background: #e3edfc; }
    .sidebar-avatar {
        width: 36px; height: 36px; border-radius: 50%; flex-shrink: 0;
        background: var(--sona-surface-strong); color: var(--sona-coral); display: flex; align-items: center; justify-content: center; font-size: 14px;
    }
    .sidebar-avatar.female { background: var(--sona-surface-strong); color: var(--sona-coral-deep); }
    .sidebar-name { font-size: 14px; font-weight: 600; }

    /* 角色目錄頁：main-panel 內容改成多欄卡片網格，卡片本身直向排列
       （頭像在上、文字在下），跟手機版的橫向單欄清單風格不同。 */
    .main-panel--catalog { padding: 32px 40px; overflow-y: auto; }
    .main-panel--catalog header.top { position: static; padding: 0 0 20px; border-bottom: none; }
    .main-panel--catalog header.top h1 { text-align: left; font-size: 24px; }
    .main-panel--catalog .tabs { max-width: 260px; padding: 0 0 24px; }
    .main-panel--catalog .catalog-list {
        padding: 0;
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
        gap: 16px;
    }
    .main-panel--catalog .char-card { flex-direction: column; text-align: center; padding: 20px; }
    .main-panel--catalog .char-avatar { width: 72px; height: 72px; font-size: 28px; margin: 0 auto 12px; }
    .main-panel--catalog .char-tags,
    .main-panel--catalog .char-bio { text-align: left; }

    /* 角色詳情頁：改成左頭像、右文字的橫向排版，用 CSS Grid 的
       grid-template-areas 直接對應現有的元素 class，不用改 HTML 結構。 */
    .main-panel--detail { padding: 0 40px 40px; overflow-y: auto; }
    .main-panel--detail header.top { margin: 0 -40px 20px; padding-left: 40px; padding-right: 40px; }
    .main-panel--detail {
        display: grid;
        grid-template-columns: 220px 1fr;
        grid-template-rows: auto auto auto auto 1fr auto;
        grid-template-areas:
            "header header"
            "avatar name"
            "avatar tagline"
            "avatar tags"
            "avatar bio"
            "avatar actions";
        column-gap: 32px;
        row-gap: 6px;
        align-items: start;
    }
    .main-panel--detail header.top { grid-area: header; }
    .main-panel--detail .detail-avatar { grid-area: avatar; margin: 0; width: 220px; height: 220px; font-size: 64px; align-self: start; }
    .main-panel--detail .detail-name { grid-area: name; text-align: left; margin-top: 24px; }
    .main-panel--detail .detail-tagline { grid-area: tagline; text-align: left; margin-bottom: 4px; }
    .main-panel--detail .detail-tags { grid-area: tags; text-align: left; margin-bottom: 8px; }
    .main-panel--detail .detail-tags span { margin: 0 6px 0 0; }
    .main-panel--detail .detail-bio { grid-area: bio; padding: 0; max-width: 520px; }
    .main-panel--detail .detail-actions { grid-area: actions; padding: 0; max-width: 320px; margin-top: 20px; }

    /* 聊天室：main-panel 本身維持跟手機版一樣的 flex column（訊息可捲動、
       輸入框固定底部），只是限制一個好閱讀的寬度並置中，不要整個拉滿到
       側邊欄旁邊的邊界。 */
    .main-panel--chat { align-items: center; }
    .main-panel--chat > * { width: 100%; max-width: 720px; }

    /* 桌面版沒有底部分頁列，輸入框改回原本跟著版面走的固定定位（不用像手機版
       那樣浮在畫面最下面），.messages 的額外留白也一起改回來。 */
    .main-panel--chat .composer {
        position: static; max-width: 720px; margin: 0; z-index: auto;
    }
    .main-panel--chat .messages {
        padding: 16px;
    }
}

/* 心動錢包（account.php，2026-08-07 排入）——純顯示卡片，樣式比照 .wa-panel
   系列既有元件，不是全新的一套視覺語言。 */
.wallet-card { border: 1px solid #eee; border-radius: 12px; padding: 16px; margin: 16px 0; }
.wallet-tier-row { display: flex; align-items: center; justify-content: space-between; }
.wallet-tier { font-size: 20px; font-weight: 700; }
.wallet-divider { height: 1px; background: #eee; margin: 12px 0; }
.wallet-usage-row { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; font-size: 14px; }
.wallet-usage-row span { font-size: 18px; width: 24px; text-align: center; }

/* 語音通話（chat.php，2026-08-07 排入，網頁版固定走 ElevenLabs）——通話中的
   全覆蓋層，樣式呼應 .detail-avatar 系列既有的圓形頭像視覺。 */
/* 這個 class 同時用在 <button>（📞 通話）跟 <a>（⚙️ 聊天設定，見 chat.php header-actions）
   兩種標籤上，inline-flex + text-decoration:none 讓兩者視覺完全一致。 */
.call-icon-btn {
    background: none; border: none; font-size: 20px; cursor: pointer; padding: 4px 8px;
    color: var(--sona-coral-deep); display: inline-flex; align-items: center; justify-content: center;
    text-decoration: none;
}
.call-overlay {
    /* z-index 35：比 .tabbar（30）跟 .composer（15）都高，通話中要蓋住
       整個畫面（含底部分頁列跟輸入框），不能讓使用者在通話時還能點到別的分頁。 */
    position: absolute; inset: 0; background: #fff; z-index: 35;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 12px; padding: 24px; text-align: center;
}
.call-avatar {
    width: 120px; height: 120px; border-radius: 50%; display: flex; align-items: center;
    justify-content: center; font-size: 48px; background: var(--sona-surface-strong); color: var(--sona-coral);
}
.call-avatar.female { background: var(--sona-surface-strong); color: var(--sona-coral-deep); }
.call-name { font-size: 20px; font-weight: 700; }
.call-status { color: #777; font-size: 14px; }
.call-timer { font-size: 32px; font-weight: 700; font-variant-numeric: tabular-nums; }
.call-low-balance { color: #c0392b; font-size: 13px; }
.call-controls { display: flex; gap: 24px; margin-top: 12px; }
.call-control-btn {
    width: 56px; height: 56px; border-radius: 50%; border: none; font-size: 22px;
    background: #eee; cursor: pointer;
}
.call-control-btn--danger { background: #d64545; color: #fff; }

/* 真實頭像照片（2026-08-07 補上，之前只有字母佔位圓圈，見計畫檔案的說明）——
   跟同名的字母版本共用尺寸/圓角，只是換成 <img> 標籤，加 object-fit 避免照片
   被拉伸變形。 */
.char-avatar--photo,
.detail-avatar--photo,
.sidebar-avatar--photo,
.call-avatar--photo {
    object-fit: cover; display: block;
}

/* 手機版底部分頁列（2026-08-07 排入，視覺格局比照 iOS RootTabView 的三分頁：
   消息／角色／我的）。桌面版用側邊欄導覽，>=900px 隱藏（跟 .sidebar 相反的
   顯示邏輯）。呼叫端要設定 $activeTab 為 'messages'/'catalog'/'profile' 之一，
   見 partials/tabbar.php。 */
.tabbar {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
    display: flex; max-width: 480px; margin: 0 auto;
    background: #fff; border-top: 1px solid #eee;
    padding-bottom: env(safe-area-inset-bottom, 0);
}
.tabbar-item {
    flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px;
    padding: 8px 0 6px; text-decoration: none; color: #aaa; font-size: 11px; font-weight: 600;
}
.tabbar-item.active { color: var(--sona-coral-deep); }
.tabbar-icon { font-size: 21px; line-height: 1; }
@media (min-width: 900px) {
    .tabbar { display: none; }
}

/* 消息（messages.php，2026-08-07 排入）——列出本機有聊天記錄的角色，比照
   iOS MessagesListView：頭像＋姓名＋最後一則訊息預覽，點進去開聊天室。 */
.message-row {
    display: flex; align-items: center; gap: 12px; padding: 10px 16px;
    text-decoration: none; color: inherit;
}
.message-row-name { font-weight: 700; font-size: 15px; }
.message-row-preview {
    font-size: 13px; color: #888; margin-top: 2px;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 260px;
}
.messages-empty {
    padding: 60px 32px; text-align: center; color: #999; font-size: 14px; line-height: 1.8;
}

/* 每日簽到橫幅（index.php）——Turnstile 小工具本身有固定的最小寬度（Cloudflare
   官方元件，不能縮），窄螢幕（手機版）左右並排會把左邊文字擠成直排逐字換行，
   改成上下堆疊；桌面版夠寬才並排。 */
.checkin-banner {
    padding: 12px 16px; border-bottom: 1px solid #eee;
    display: flex; flex-direction: column; gap: 12px;
}
.checkin-banner-title { font-weight: 700; font-size: 14px; }
.checkin-banner-action { display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
@media (min-width: 520px) {
    .checkin-banner { flex-direction: row; align-items: center; justify-content: space-between; }
    .checkin-banner-action { flex-direction: row; align-items: center; }
}

/* 聊天設定（chat-settings.php／voice-library.php，2026-08-07 排入，比照 iOS
   ChatSettingsView 搬到網頁版）。.settings-body 額外留一段 padding-bottom，
   道理跟 .messages 一樣——手機版底部有固定分頁列，最後一個區塊捲到底不能被蓋住；
   這頁沒有像聊天室那樣固定定位的輸入框，所以不用留到 128px 那麼多，56px 分頁列
   高度＋一點緩衝就夠。桌面版（900px media query）改回一般 padding。 */
.settings-body {
    padding: 16px 16px calc(72px + env(safe-area-inset-bottom, 0px));
    display: flex; flex-direction: column; gap: 20px; overflow-y: auto;
}
.settings-section { position: relative; }
.settings-section.locked { opacity: 0.45; }
.settings-lock-overlay { position: absolute; inset: 0; z-index: 5; cursor: pointer; }
.settings-label { display: block; font-weight: 700; font-size: 15px; margin-bottom: 6px; }
.settings-hint { font-size: 12px; color: #888; margin: 4px 0 8px; line-height: 1.6; }
.settings-row-edit { display: flex; gap: 8px; }
.settings-row-edit input {
    flex: 1; border: 1px solid #ddd; background: #fafafa; border-radius: 12px;
    padding: 10px 14px; font-size: 16px;
}
.settings-textarea {
    width: 100%; min-height: 110px; border: 1px solid #ddd; background: #fafafa;
    border-radius: 12px; padding: 10px 14px; font-size: 16px; font-family: inherit;
    resize: vertical; margin-bottom: 8px;
}
.btn-small {
    border: none; background: var(--sona-coral-deep); color: #fff; border-radius: 20px;
    padding: 10px 18px; font-size: 14px; font-weight: 600; cursor: pointer; white-space: nowrap;
}
.btn-small:disabled { background: #ccc; }
.btn-secondary-small {
    border: 1px solid #ddd; background: #fff; color: #666; border-radius: 20px;
    padding: 9px 16px; font-size: 13px; cursor: pointer;
}
.btn-file { display: inline-block; text-align: center; }
.avatar-edit-row { display: flex; align-items: center; gap: 16px; }
.settings-avatar-preview {
    width: 64px; height: 64px; border-radius: 50%; object-fit: cover; background: #eee; flex-shrink: 0;
}
.avatar-edit-actions { display: flex; flex-direction: column; gap: 8px; }
.settings-row-link {
    display: flex; align-items: center; justify-content: space-between;
    text-decoration: none; color: inherit; padding: 12px 14px; background: #fafafa;
    border-radius: 12px; font-size: 15px;
}
.settings-row-link .chevron { color: #bbb; font-size: 18px; }
.journey-settings-card { padding:16px; border:1px solid var(--sona-line); border-radius:18px; background:linear-gradient(135deg,#FFF9F6,#eef5ff); }.journey-settings-head { display:flex; align-items:flex-start; justify-content:space-between; gap:14px; }.journey-settings-head .settings-label { margin:0 0 4px; }.journey-settings-head p { max-width:430px; margin:0; color:#75839a; font-size:11px; line-height:1.6; }.journey-switch { position:relative; width:46px; height:27px; flex:0 0 auto; cursor:pointer; }.journey-switch input { position:absolute; opacity:0; pointer-events:none; }.journey-switch span { position:absolute; inset:0; border-radius:999px; background:#cbd5e1; transition:.2s ease; }.journey-switch span::after { content:""; position:absolute; width:21px; height:21px; top:3px; left:3px; border-radius:50%; background:#fff; box-shadow:0 2px 5px rgba(22,35,57,.2); transition:.2s ease; }.journey-switch input:checked + span { background:var(--sona-coral); }.journey-switch input:checked + span::after { transform:translateX(19px); }.journey-switch input:focus-visible + span { outline:3px solid rgba(var(--sona-coral-rgb),.24); outline-offset:2px; }.journey-settings-card .btn-secondary-small { margin-top:5px; }
.slider-row { margin-bottom: 16px; }
.slider-row:last-child { margin-bottom: 0; }
.slider-label-row { display: flex; justify-content: space-between; font-size: 14px; margin-bottom: 6px; }
.slider-label-row span:last-child { color: #888; font-variant-numeric: tabular-nums; }
.slider-row input[type="range"] { width: 100%; accent-color: var(--sona-coral-deep); }

@media (min-width: 900px) {
    .main-panel--settings { align-items: center; }
    .main-panel--settings > * { width: 100%; max-width: 640px; }
    .settings-body { padding: 24px 0 24px; overflow-y: visible; }
}

/* 語音庫選聲音頁（voice-library.php）——列表卡片樣式跟 .char-card 系列同一個
   語言（圓角卡片、次要文字用灰色小標籤），但這裡是聲音不是角色，獨立一組 class。 */
.voice-search-row { display: flex; gap: 8px; margin-bottom: 4px; }
.voice-search-row input {
    flex: 1; border: 1px solid #ddd; background: #fafafa; border-radius: 12px;
    padding: 10px 14px; font-size: 16px;
}
.voice-list { display: flex; flex-direction: column; gap: 10px; }
.voice-card {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    padding: 14px; border-radius: 14px; background: #fafafa;
}
.voice-card-name { font-weight: 700; font-size: 15px; }
.voice-card-badges { margin: 4px 0; }
.voice-card-badges span {
    display: inline-block; background: #eee; border-radius: 10px; padding: 2px 8px;
    font-size: 11px; margin-right: 4px; color: #666;
}
.voice-card-desc { font-size: 12px; color: #888; line-height: 1.5; }
.voice-card-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; flex-shrink: 0; }
.voice-preview-btn {
    border: 1px solid #ddd; background: #fff; border-radius: 50%; width: 36px; height: 36px;
    font-size: 15px; cursor: pointer;
}
.voice-use-btn { padding: 8px 14px; font-size: 12px; }

/* 法律文件頁（privacy.php／terms.php，2026-08-07 排入）——刻意不套用 .shell/
   .tabbar 那套 App 內部版型（這兩頁公開、免登入，訪客跟 App Store 審核者都可能
   直接開連結進來，不該看到側邊欄或分頁列）。排版走可讀性優先：限制單行寬度、
   段落間距、標題階層，跟官網 lythorix.us 的沉穩調性呼應，但顏色沿用 Sona
   自己的 var(--sona-coral-deep) 强調色，不是官網那組深綠＋萊姆黃（兩個不同子品牌，不用硬套）。 */
.legal-body { background: #fafafa; }
.legal-shell { max-width: 720px; margin: 0 auto; padding: 48px 24px 80px; }
.legal-header { margin-bottom: 40px; }
.legal-header-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; }
.legal-back { display: inline-block; color: var(--sona-coral-deep); text-decoration: none; font-size: 13px; font-weight: 600; margin-bottom: 0; }
.legal-lang-switch {
    color: #666; text-decoration: none; font-size: 13px; font-weight: 600;
    border: 1px solid #ddd; border-radius: 14px; padding: 4px 12px;
}
.legal-lang-switch:hover { border-color: var(--sona-coral-deep); color: var(--sona-coral-deep); }
.legal-kicker { font-size: 11px; font-weight: 700; letter-spacing: 0.12em; color: var(--sona-coral-deep); margin-bottom: 10px; }
.legal-header h1 { font-size: 32px; margin: 0 0 8px; letter-spacing: -0.01em; }
.legal-policy-tabs { display: flex; flex-wrap: wrap; gap: 7px; margin: 0 0 24px; padding-bottom: 18px; border-bottom: 1px solid #e8eaee; }
.legal-policy-tabs a { padding: 6px 10px; border: 1px solid #e1e4e8; border-radius: 999px; color: #697386; text-decoration: none; font-size: 12px; font-weight: 650; }
.legal-policy-tabs a:hover, .legal-policy-tabs a[aria-current="page"] { border-color: var(--sona-coral); background: #fff3ef; color: var(--sona-coral-deep); }
.legal-meta { font-size: 13px; color: #999; }
.legal-doc { font-size: 15px; line-height: 1.85; color: #333; }
.legal-doc h2 { font-size: 19px; margin: 40px 0 14px; color: #111; }
.legal-doc h2:first-child { margin-top: 0; }
.legal-doc h3 { font-size: 16px; margin: 28px 0 10px; color: #111; }
.legal-doc p { margin: 0 0 16px; }
.legal-doc ul, .legal-doc ol { margin: 0 0 16px; padding-left: 22px; }
.legal-doc li { margin-bottom: 8px; }
.legal-doc a { color: var(--sona-coral-deep); }
.legal-doc code { background: #f0f0f0; padding: 1px 6px; border-radius: 4px; font-size: 13px; }
.legal-contact { list-style: none; padding: 0; }
.legal-contact li { margin-bottom: 6px; }
.policy-table { overflow-x: auto; margin: 22px 0 28px; border: 1px solid #e4e6eb; border-radius: 12px; background: #fff; }
.policy-table table { width: 100%; min-width: 610px; border-collapse: collapse; font-size: 13px; line-height: 1.55; }
.policy-table th, .policy-table td { padding: 12px 14px; border-bottom: 1px solid #edf0f3; text-align: left; vertical-align: top; }
.policy-table th { background: #f7f8fa; color: #555; font-size: 12px; }
.policy-table tr:last-child td { border-bottom: 0; }
.legal-footer { margin-top: 44px; padding-top: 18px; border-top: 1px solid #e5e7eb; color: #8a929e; font-size: 12px; }
.legal-footer a { color: var(--sona-coral-deep); text-decoration: none; }
.legal-lang-switch select { border: 0; background: transparent; color: inherit; font: inherit; cursor: pointer; }
.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; }
@media (min-width: 640px) {
    .legal-shell { padding: 72px 24px 100px; }
    .legal-header h1 { font-size: 40px; }
}

/* 行銷首頁（home.php）：此區樣式只作用於 .home-*，不影響 App 內頁。 */
.home-body {
    --home-blue: var(--sona-coral);
    --home-blue-deep: var(--sona-coral-deep);
    --home-ink: #111827;
    --home-muted: #667085;
    --home-line: #e8edf5;
    background: #fff; color: var(--home-ink); padding-bottom: 0; overflow-x: hidden;
}
.home-body main { display: block; }
.home-body a, .home-body button { -webkit-tap-highlight-color: transparent; }
.home-body [id] { scroll-margin-top: 82px; }

.home-nav {
    position: sticky; top: 0; z-index: 20; background: rgba(255,255,255,0.88);
    backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); border-bottom: 1px solid rgba(232,237,245,0.8);
}
.home-nav-inner { max-width: 1200px; margin: 0 auto; min-height: 72px; padding: 12px 28px; display: flex; align-items: center; gap: 34px; }
.home-brand { display: flex; align-items: center; gap: 10px; color: var(--home-ink); text-decoration: none; font-weight: 850; font-size: 19px; letter-spacing: -0.02em; flex-shrink: 0; }
.home-brand-badge { width: 36px; height: 36px; border-radius: 11px; display: block; object-fit: cover; box-shadow: 0 5px 14px rgba(13,79,183,0.18); }
.home-nav-links { display: none; align-items: center; gap: 30px; flex: 1; font-size: 13px; font-weight: 650; }
.home-nav-links a { color: #4b5565; text-decoration: none; transition: color .2s ease; }
.home-nav-links a:hover { color: var(--home-blue); }
.home-nav-cta { margin-left: auto; display: inline-flex; align-items: center; gap: 9px; background: var(--home-ink); color: #fff; text-decoration: none; padding: 11px 17px; border-radius: 999px; font-size: 13px; font-weight: 750; box-shadow: 0 8px 20px rgba(17,24,39,.13); transition: transform .2s ease, box-shadow .2s ease; }
.home-nav-cta:hover { transform: translateY(-1px); box-shadow: 0 11px 24px rgba(17,24,39,.18); }
.home-nav-cta span { font-size: 17px; line-height: 1; }
.home-policy-grid { max-width: 1200px; margin: 0 auto; padding: 76px 28px 96px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; background: #fff; }
.home-policy-card { scroll-margin-top: 92px; padding: 28px; border: 1px solid #f0deda; border-radius: 20px; background: #fffaf8; }
.home-policy-card--wide { grid-column: 1 / -1; }
.home-policy-card .home-kicker { margin-bottom: 12px; }
.home-policy-card h2 { margin: 0 0 10px; font-size: 23px; letter-spacing: -.03em; color: var(--home-ink); }
.home-policy-card p { margin: 0; color: #687386; font-size: 14px; line-height: 1.75; }
@media (max-width: 700px) { .home-policy-grid { grid-template-columns: 1fr; padding: 54px 18px 70px; } .home-policy-card--wide { grid-column: auto; } }

.home-kicker { display: flex; align-items: center; gap: 9px; font-size: 11px; font-weight: 800; letter-spacing: .16em; color: var(--home-blue); text-transform: uppercase; margin-bottom: 20px; }
.home-kicker > span { width: 25px; height: 1px; background: currentColor; }
.home-hero { position: relative; background: radial-gradient(circle at 84% 18%, rgba(79,151,255,.18), transparent 31%), radial-gradient(circle at 18% 32%, rgba(229,239,255,.8), transparent 32%), linear-gradient(180deg,#fbfdff 0%,#fff 88%); }
.home-hero::before { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .4; background-image: radial-gradient(#b8cbed 1px, transparent 1px); background-size: 30px 30px; mask-image: linear-gradient(to bottom, black, transparent 72%); }
.home-hero-inner { position: relative; z-index: 1; max-width: 1200px; margin: 0 auto; padding: 72px 28px 44px; display: grid; align-items: center; gap: 58px; }
.home-hero-text { max-width: 650px; }
.home-hero-text h1 { font-size: clamp(43px, 8.5vw, 72px); line-height: 1.08; margin: 0 0 26px; letter-spacing: -.055em; font-weight: 850; }
.home-hero-text h1 span { display: inline-block; color: var(--home-blue); position: relative; }
.home-hero-text h1 span::after { content: ""; position: absolute; left: 2%; right: -2%; bottom: -8px; height: 10px; border-top: 3px solid #FFB1A0; border-radius: 50%; transform: rotate(-1.5deg); }
.home-lede { font-size: 16px; line-height: 1.9; color: #586274; max-width: 590px; margin: 0 0 30px; }
.home-cta-row { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.home-cta-primary { display: inline-flex; align-items: center; justify-content: center; gap: 14px; min-height: 52px; padding: 0 23px; border-radius: 999px; background: var(--home-blue); color: #fff; text-decoration: none; font-size: 15px; font-weight: 750; box-shadow: 0 13px 27px rgba(var(--sona-coral-rgb),.26); transition: transform .2s ease, box-shadow .2s ease; }
.home-cta-primary:hover { transform: translateY(-2px); box-shadow: 0 17px 32px rgba(var(--sona-coral-rgb),.32); }
.home-cta-primary > span { width: 25px; height: 25px; display: grid; place-items: center; border-radius: 50%; background: rgba(255,255,255,.18); font-size: 16px; }
.home-cta-secondary { display: inline-flex; align-items: center; gap: 9px; color: #273142; text-decoration: none; font-weight: 700; font-size: 14px; padding: 12px 8px; }
.home-play-icon { width: 31px; height: 31px; display: grid; place-items: center; border: 1px solid #cfd8e6; border-radius: 50%; color: var(--home-blue); font-size: 9px; padding-left: 2px; background: #fff; }
.home-hero-note { display: flex; align-items: center; gap: 8px; margin-top: 23px; color: #7b8494; font-size: 12px; font-weight: 600; }
.home-online-dot { width: 8px; height: 8px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 4px rgba(34,197,94,.12); }

.home-hero-visual { position: relative; height: 510px; min-width: 0; }
.home-chat-card { position: absolute; width: min(360px, 78vw); left: 50%; top: 50%; transform: translate(-50%,-50%) rotate(-1.5deg); border: 1px solid rgba(213,224,240,.9); border-radius: 29px; background: rgba(255,255,255,.94); box-shadow: 0 35px 80px rgba(41,76,125,.17), 0 8px 24px rgba(41,76,125,.08); overflow: hidden; }
.home-chat-head { display: flex; align-items: center; gap: 11px; padding: 17px 19px; border-bottom: 1px solid #edf1f6; }
.home-chat-brand-mark img { width: 39px; height: 39px; display: block; border-radius: 12px; }
.home-chat-head > div:nth-child(2) { display: flex; flex-direction: column; gap: 3px; }
.home-chat-head strong { font-size: 14px; }
.home-chat-head span { display: flex; align-items: center; gap: 5px; font-size: 10px; color: #7b8494; }
.home-chat-head i { display: block; width: 6px; height: 6px; background: #22c55e; border-radius: 50%; }
.home-chat-more { margin-left: auto; color: #a2aab8 !important; letter-spacing: 2px; }
.home-chat-body { min-height: 274px; padding: 16px 18px 13px; background: linear-gradient(180deg,#FFFDFC,#FFF8F5); }
.home-chat-time { margin: 0 0 15px; text-align: center; color: #a3abb7; font-size: 9px; }
.home-chat-bubble { width: fit-content; max-width: 78%; padding: 11px 14px; border-radius: 17px; font-size: 12px; line-height: 1.55; box-shadow: 0 5px 14px rgba(31,67,118,.06); }
.home-chat-bubble--left { background: #fff; color: #364153; border-bottom-left-radius: 5px; }
.home-chat-bubble--right { margin: 14px 0 12px auto; background: var(--home-blue); color: #fff; border-bottom-right-radius: 5px; }
.home-chat-typing { display: flex; align-items: center; gap: 4px; width: 52px; height: 29px; padding: 0 13px; background: #fff; border-radius: 15px; box-shadow: 0 5px 14px rgba(31,67,118,.06); }
.home-chat-typing span { width: 4px; height: 4px; background: #aab4c2; border-radius: 50%; }
.home-chat-input { margin: 13px 15px 15px; padding: 7px 7px 7px 15px; display: flex; align-items: center; color: #a4adba; border: 1px solid #e3e9f2; border-radius: 999px; font-size: 11px; }
.home-chat-input b { margin-left: auto; width: 28px; height: 28px; display: grid; place-items: center; background: var(--home-blue); color: #fff; border-radius: 50%; font-size: 13px; }
.home-hero-avatar-item { position: absolute; z-index: 2; display: flex; align-items: center; gap: 7px; padding: 5px 10px 5px 5px; border: 1px solid rgba(219,228,241,.9); border-radius: 999px; background: rgba(255,255,255,.94); color: #344054; text-decoration: none; font-size: 10px; font-weight: 700; box-shadow: 0 10px 25px rgba(41,76,125,.13); backdrop-filter: blur(10px); transition: transform .2s ease; }
.home-hero-avatar-item:hover { transform: translateY(-3px); }
.home-hero-avatar-img { width: 37px; height: 37px; border-radius: 50%; object-fit: cover; background: #e4edfb; display: grid; place-items: center; color: var(--home-blue); }
.home-hero-avatar-item--1 { top: 2%; left: 1%; }
.home-hero-avatar-item--2 { top: 9%; right: 0; }
.home-hero-avatar-item--3 { top: 46%; left: -2%; }
.home-hero-avatar-item--4 { top: 55%; right: -1%; }
.home-hero-avatar-item--5 { bottom: 1%; left: 10%; }
.home-hero-avatar-item--6 { bottom: 3%; right: 8%; }
.home-hero-avatar-item:nth-child(n+7) { display: none; }
.home-voice-pill { position: absolute; z-index: 3; top: 16%; left: 3%; display: flex; align-items: center; gap: 8px; padding: 9px 13px; background: var(--home-ink); color: #fff; border-radius: 999px; font-size: 10px; font-weight: 700; box-shadow: 0 12px 24px rgba(17,24,39,.18); }
.home-voice-pill span { color: #FFC1B4; letter-spacing: 2px; font-size: 8px; transform: skewY(-12deg); }
.home-hero-stats { position: relative; z-index: 1; max-width: 1144px; margin: 0 auto; padding: 0 28px 48px; display: grid; grid-template-columns: repeat(3,1fr); }
.home-hero-stats > div { min-width: 0; display: flex; flex-direction: column; gap: 5px; padding: 20px 5vw; border-top: 1px solid var(--sona-line); }
.home-hero-stats > div + div { border-left: 1px solid var(--sona-line); }
.home-hero-stats strong { font-size: clamp(18px,2vw,24px); letter-spacing: -.03em; white-space: nowrap; }
.home-hero-stats span { color: #7b8494; font-size: 11px; white-space: nowrap; }

.home-section { max-width: 1200px; margin: 0 auto; padding: 105px 28px; }
.home-section-head { display: grid; gap: 24px; margin-bottom: 45px; }
.home-section-head > p { max-width: 440px; margin: 0; color: var(--home-muted); font-size: 15px; line-height: 1.85; }
.home-section-title { margin: 0; font-size: clamp(33px,5vw,50px); line-height: 1.16; letter-spacing: -.045em; }
.home-section-title em { color: var(--home-blue); font-style: normal; }
.home-feature-grid { display: grid; grid-template-columns: 1fr; gap: 16px; }
.home-feature-card { position: relative; min-height: 300px; padding: 29px; overflow: hidden; border: 1px solid var(--home-line); border-radius: 26px; background: #f8fafc; }
.home-feature-card::after { content: ""; position: absolute; width: 210px; height: 210px; right: -110px; bottom: -130px; border-radius: 50%; background: rgba(var(--sona-coral-rgb),.07); }
.home-feature-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 42px; }
.home-feature-icon { width: 42px; height: 42px; display: grid; place-items: center; border: 1px solid var(--sona-line); border-radius: 13px; background: #fff; color: var(--home-blue); font-size: 20px; box-shadow: 0 5px 12px rgba(45,76,119,.07); }
.home-feature-num { color: #95a0b1; font-size: 11px; font-weight: 800; letter-spacing: .1em; }
.home-feature-card h3 { margin: 0 0 11px; font-size: 23px; letter-spacing: -.025em; }
.home-feature-card p { position: relative; z-index: 2; max-width: 470px; margin: 0; color: var(--home-muted); font-size: 14px; line-height: 1.8; }
.home-feature-card--primary { background: var(--sona-surface); border-color: var(--sona-line); }
.home-feature-card--dark { background: #111827; border-color: #111827; color: #fff; }
.home-feature-card--dark::after { background: rgba(81,145,255,.13); }
.home-feature-card--dark .home-feature-icon { border-color: rgba(255,255,255,.13); background: rgba(255,255,255,.08); color: #8fbcff; }
.home-feature-card--dark .home-feature-num, .home-feature-card--dark p { color: #aeb9ca; }
.home-feature-demo { display: flex; flex-direction: column; align-items: flex-end; gap: 7px; margin: 22px 0 0 auto; width: 165px; }
.home-feature-demo span { padding: 8px 11px; border-radius: 12px 12px 3px 12px; background: #fff; color: #5d6a7e; box-shadow: 0 5px 12px rgba(45,76,119,.07); font-size: 10px; }
.home-feature-demo span:last-child { margin-right: 25px; background: var(--home-blue); color: #fff; }
.home-wave { position: absolute; right: 25px; bottom: 28px; height: 55px; display: flex; align-items: center; gap: 5px; }
.home-wave i { width: 4px; height: 18px; border-radius: 4px; background: #FFB1A0; }
.home-wave i:nth-child(2n) { height: 34px; }.home-wave i:nth-child(3n) { height: 47px; }.home-wave i:nth-child(5) { height: 25px; }
.home-memory-tags { position: absolute; left: 29px; bottom: 27px; right: 29px; display: flex; flex-wrap: wrap; gap: 7px; }
.home-memory-tags span { padding: 7px 11px; border: 1px solid #dbe3ef; border-radius: 999px; background: #fff; color: #687386; font-size: 10px; }
.home-device-row { position: absolute; left: 29px; right: 29px; bottom: 29px; display: flex; align-items: center; gap: 9px; color: #d6deeb; font-size: 10px; }
.home-device-row span { padding: 7px 10px; border-radius: 8px; background: rgba(255,255,255,.08); }
.home-device-row i { flex: 1; height: 1px; background: rgba(255,255,255,.14); }

.home-download { padding-top: 30px; padding-bottom: 110px; }
.home-download-card { position: relative; min-height: 550px; overflow: hidden; display: grid; align-items: center; padding: 58px 30px; border-radius: 34px; background: radial-gradient(circle at 82% 18%,rgba(255,138,114,.58),transparent 30%),linear-gradient(135deg,#3A1E25 0%,#C9404C 58%,var(--sona-coral) 100%); color: #fff; box-shadow: 0 25px 65px rgba(233,67,78,.22); }
.home-download-card::before { content: ""; position: absolute; inset: 0; opacity: .13; background-image: radial-gradient(#fff 1px,transparent 1px); background-size: 24px 24px; mask-image: linear-gradient(90deg,black,transparent); }
.home-download-copy { position: relative; z-index: 2; max-width: 590px; }
.home-kicker--light { color: #9ac0ff; }
.home-download .home-section-title { margin-bottom: 22px; font-size: clamp(38px,6vw,57px); }
.home-download-copy > p { max-width: 520px; margin: 0 0 27px; color: #d7e5fa; font-size: 15px; line-height: 1.85; }
.home-cta-primary--light { background: #fff; color: #0d4ebc; box-shadow: 0 14px 29px rgba(3,21,50,.24); }
.home-cta-primary--light > span { background: var(--sona-surface); }
.home-badge-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 25px; }
.home-store-badge { display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 8px 15px 8px 12px; border: 1px solid rgba(255,255,255,.22); border-radius: 13px; background: rgba(3,21,50,.28); color: #fff; cursor: pointer; text-align: left; backdrop-filter: blur(8px); }
.home-store-badge-icon { width: 24px; height: 24px; flex-shrink: 0; display: block; background: #fff; -webkit-mask-size: contain; mask-size: contain; -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; -webkit-mask-position: center; mask-position: center; -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M16.36 1.43c.1 1.02-.28 2-.87 2.72-.6.73-1.6 1.3-2.6 1.22-.11-1 .33-2.03.92-2.71.63-.73 1.7-1.28 2.55-1.23zM20.6 17.2c-.3.7-.66 1.36-1.1 1.98-.6.87-1.1 1.47-1.5 1.8-.62.55-1.28.83-1.99.85-.51 0-1.13-.15-1.85-.45-.72-.3-1.38-.44-1.98-.44-.63 0-1.31.15-2.04.44-.73.3-1.32.46-1.77.47-.68.03-1.36-.26-2.03-.87-.43-.36-.96-.98-1.58-1.87-.67-.95-1.22-2.05-1.65-3.31-.46-1.36-.69-2.68-.69-3.96 0-1.47.32-2.74.95-3.8a5.6 5.6 0 0 1 1.99-2.02 5.36 5.36 0 0 1 2.7-.76c.54 0 1.25.17 2.13.5.88.33 1.44.5 1.7.5.19 0 .82-.19 1.87-.58 1-.36 1.83-.51 2.51-.46 1.86.15 3.25.88 4.18 2.2-1.66 1-2.49 2.42-2.47 4.24.01 1.42.53 2.6 1.55 3.55.46.44.98.78 1.55 1.02-.12.36-.25.72-.4 1.06z'/%3E%3C/svg%3E"); }
.home-store-badge-icon--android { -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M3 20.5V3.5c0-.44.24-.83.6-1.03l10.9 9.53-10.9 9.53c-.36-.2-.6-.6-.6-1.03zM16.8 12l2.75-1.6 2.9 1.6a1.18 1.18 0 0 1 0 2.05l-2.9 1.6-2.75-1.6-1.7-2.05 1.7-2zm-1.45 1.4-9.9 8.66 9.16-5.05 2.55-1.45-1.81-2.16zm0-2.8 1.81-2.16-2.55-1.45L5.45 1.94l9.9 8.66z'/%3E%3C/svg%3E"); }
.home-store-badge-text { display: flex; flex-direction: column; line-height: 1.18; font-size: 14px; font-weight: 700; }
.home-store-badge-text small { font-size: 8px; font-weight: 500; text-transform: uppercase; letter-spacing: .06em; color: #bcd1ef; }
.home-download-art { display: none; position: relative; z-index: 1; min-height: 470px; }
.home-phone { position: absolute; z-index: 2; width: 238px; height: 456px; right: 14%; top: 50%; transform: translateY(-50%) rotate(7deg); display: flex; flex-direction: column; align-items: center; padding: 66px 18px 20px; border: 8px solid #091425; border-radius: 39px; background: linear-gradient(160deg,#f8fbff,#dbe9ff); color: #14213a; box-shadow: 0 34px 60px rgba(2,14,35,.44); }
.home-phone-notch { position: absolute; top: 10px; left: 50%; transform: translateX(-50%); width: 84px; height: 21px; border-radius: 20px; background: #091425; }
.home-phone img { width: 66px; height: 66px; margin-top: 30px; border-radius: 19px; box-shadow: 0 12px 25px rgba(13,79,183,.25); }
.home-phone strong { margin-top: 18px; font-size: 22px; }
.home-phone span { margin-top: 8px; color: #647187; font-size: 11px; }
.home-phone i { width: 100%; margin-top: auto; padding: 12px; border-radius: 999px; background: var(--home-blue); color: #fff; font-size: 11px; font-style: normal; font-weight: 700; text-align: center; }
.home-orbit { position: absolute; border: 1px solid rgba(255,255,255,.15); border-radius: 50%; }
.home-orbit--one { width: 380px; height: 380px; right: 1%; top: 9%; }.home-orbit--two { width: 520px; height: 520px; right: -14%; top: -5%; }

.home-footer { padding: 65px 28px 28px; background: #f8fafc; border-top: 1px solid var(--home-line); }
.home-footer-inner { max-width: 1144px; margin: 0 auto; display: flex; flex-direction: column; gap: 40px; }
.home-brand--footer { width: fit-content; margin-bottom: 16px; }
.home-footer-desc { margin: 0; max-width: 360px; color: #7b8494; font-size: 13px; line-height: 1.8; }
.home-footer-links { display: grid; grid-template-columns: repeat(2,minmax(110px,1fr)); gap: 38px; }
.home-footer-links > div { display: flex; flex-direction: column; gap: 11px; }
.home-footer-links strong { margin-bottom: 3px; font-size: 12px; color: #273142; }
.home-footer-links a { color: #7b8494; text-decoration: none; font-size: 12px; }
.home-footer-links a:hover { color: var(--home-blue); }
.home-footer-copy { max-width: 1144px; margin: 48px auto 0; padding-top: 22px; border-top: 1px solid #e2e7ef; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; color: #9aa3b1; font-size: 10px; }
.home-locale-picker { display:inline-flex; align-items:center; gap:8px; color:#6b778a; font-weight:700; }
.home-locale-select { min-width:112px; height:32px; padding:0 30px 0 11px; border:1px solid #d7e0ec; border-radius:999px; appearance:none; -webkit-appearance:none; background:#fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='m5 7 5 5 5-5' fill='none' stroke='%236b778a' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.8'/%3E%3C/svg%3E") right 10px center/14px no-repeat; color:#273142; font:700 11px/1 inherit; cursor:pointer; box-shadow:0 4px 12px rgba(31,54,86,.06); }
.home-locale-select:focus-visible { outline:3px solid rgba(var(--sona-coral-rgb),.22); outline-offset:2px; }

@media (min-width: 700px) {
    .home-nav-links { display: flex; }
    .home-nav-cta { margin-left: 0; }
    .home-hero-inner { grid-template-columns: minmax(0,1.05fr) minmax(430px,.95fr); min-height: 690px; padding-top: 66px; }
    .home-hero-visual { height: 570px; }
    .home-section-head { grid-template-columns: 1fr .78fr; align-items: end; }
    .home-feature-grid { grid-template-columns: repeat(2,1fr); }
    .home-feature-card { min-height: 330px; }
    .home-download-card { grid-template-columns: 1.08fr .92fr; padding: 66px; }
    .home-download-art { display: block; }
    .home-footer-inner { flex-direction: row; justify-content: space-between; }
    .home-footer-links { min-width: 310px; }
}

@media (min-width: 1050px) {
    .home-feature-grid { grid-template-columns: 1.12fr .88fr .88fr; }
    .home-feature-card--primary { grid-row: span 2; min-height: 580px; }
    .home-feature-card--dark { grid-column: 2 / 4; }
    .home-feature-demo { position: absolute; right: 34px; bottom: 38px; width: 210px; }
    .home-feature-demo span { font-size: 12px; padding: 10px 14px; }
}

@media (max-width: 699px) {
    .home-nav-inner { min-height: 64px; padding: 10px 18px; }
    .home-brand { font-size: 17px; }.home-brand-badge { width: 33px; height: 33px; }
    .home-nav-cta { padding: 10px 13px; font-size: 12px; }.home-nav-cta span { display: none; }
    .home-hero-inner { padding: 55px 20px 25px; gap: 28px; }
    .home-hero-text h1 { font-size: clamp(41px,12vw,56px); }
    .home-lede { font-size: 15px; line-height: 1.8; }
    .home-cta-primary { min-height: 49px; padding: 0 19px; }.home-cta-secondary { font-size: 12px; }
    .home-hero-visual { height: 475px; margin: 0 -5px; }
    .home-chat-card { width: min(322px,79vw); }
    .home-hero-avatar-item { padding-right: 8px; font-size: 9px; }.home-hero-avatar-img { width: 32px; height: 32px; }
    .home-hero-avatar-item--1 { left: 0; }.home-hero-avatar-item--2 { right: 0; }.home-hero-avatar-item--3 { left: -1%; }.home-hero-avatar-item--4 { right: -1%; }
    .home-voice-pill { top: 17%; left: 0; }
    .home-hero-stats { padding: 0 20px 42px; }.home-hero-stats > div { padding: 16px 10px; }.home-hero-stats strong { font-size: 16px; }.home-hero-stats span { font-size: 9px; }
    .home-section { padding: 78px 20px; }
    .home-feature-card { min-height: 300px; padding: 24px; }.home-feature-top { margin-bottom: 35px; }
    .home-download { padding-top: 10px; padding-bottom: 80px; }
    .home-download-card { min-height: 540px; padding: 44px 25px; border-radius: 27px; }
    .home-download .home-section-title { font-size: 39px; }
    .home-store-badge { min-height: 49px; padding-right: 11px; }.home-store-badge-text { font-size: 12px; }
    .home-footer { padding: 50px 20px 25px; }
}

.wallet-ledger-link { color: var(--sona-coral-deep); text-decoration: none; font-size: 13px; font-weight: 600; white-space: nowrap; }

/* 明細記錄（wallet-ledger.php，2026-08-07 使用者要求，樣式參考使用者提供的截圖：
   膠囊分頁切換 全部／支出／收入，列表用「標題+日期」左、金額右的橫向排列，
   收入用 accent 色標紅、支出用預設深色，跟截圖的配色邏輯一致但換成本站的
   accent 色（var(--sona-coral-deep)）而不是截圖那組米色系。 */
.ledger-tabs {
    display: flex; gap: 6px; background: #f0f0f0; border-radius: 24px; padding: 4px;
    margin-bottom: 4px;
}
.ledger-tab {
    flex: 1; border: none; background: none; padding: 9px 0; border-radius: 20px;
    font-size: 14px; font-weight: 600; color: #888; cursor: pointer;
}
.ledger-tab.active { background: #fff; color: #222; box-shadow: 0 1px 3px rgba(0,0,0,0.08); }
.ledger-list { display: flex; flex-direction: column; }
.ledger-row {
    display: flex; align-items: center; justify-content: space-between;
    padding: 14px 0; border-bottom: 1px solid #f0f0f0;
}
.ledger-row-label { font-weight: 700; font-size: 15px; }
.ledger-row-date { font-size: 12px; color: #999; margin-top: 2px; }
.ledger-amount { font-size: 16px; font-weight: 700; font-variant-numeric: tabular-nums; }
.ledger-amount--expense { color: #222; }
.ledger-amount--income { color: var(--sona-coral-deep); }

/* 明細頁與新版帳戶中心共用同一套資訊層級；即使沒有交易，也會顯示明確空狀態。 */
.main-panel--ledger { min-width: 0; padding: 0 18px calc(90px + env(safe-area-inset-bottom,0px)); background: #fff; }
.ledger-content { width: 100%; max-width: 860px; margin: 0 auto; }
.ledger-intro { margin-bottom: 24px; padding: 20px; display: flex; align-items: center; gap: 14px; border: 1px solid var(--sona-line); border-radius: 19px; background: linear-gradient(120deg,#FFF6F2,#fbfdff); }
.ledger-intro-icon { width: 46px; height: 46px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 14px; background: var(--sona-coral); color: #fff; font-size: 19px; font-weight: 800; box-shadow: 0 9px 19px rgba(var(--sona-coral-rgb),.2); }
.ledger-intro span { color: var(--sona-coral); font-size: 7px; font-weight: 850; letter-spacing: .16em; }.ledger-intro h2 { margin: 3px 0 5px; font-size: 18px; letter-spacing: -.02em; }.ledger-intro p { margin: 0; color: #738097; font-size: 10px; line-height: 1.55; }
.ledger-page .ledger-tabs { margin: 0 0 14px; padding: 4px; border-radius: 13px; background: #eef2f7; }.ledger-page .ledger-tab { min-height: 39px; padding: 8px; border-radius: 10px; color: #7b8798; font-size: 11px; }.ledger-page .ledger-tab.active { color: var(--sona-coral); box-shadow: 0 4px 11px rgba(42,58,82,.08); }
.ledger-page .ledger-list { overflow: hidden; border: 1px solid #e3e8ef; border-radius: 18px; background: #fff; box-shadow: 0 9px 25px rgba(42,58,82,.05); }.ledger-page .ledger-row { min-height: 68px; padding: 14px 17px; border-bottom-color: #edf0f4; }.ledger-page .ledger-row:last-child { border-bottom: 0; }.ledger-page .ledger-row-label { color: #172033; font-size: 13px; }.ledger-page .ledger-row-date { color: #98a2b3; font-size: 9px; }.ledger-page .ledger-amount { font-size: 14px; }.ledger-page .ledger-amount--expense { color: #39465a; }.ledger-page .ledger-amount--income { color: var(--sona-coral); }
.ledger-state { min-height: 220px; padding: 35px 20px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }.ledger-state > span { width: 42px; height: 42px; display: grid; place-items: center; margin-bottom: 12px; border-radius: 13px; background: var(--sona-surface); color: var(--sona-coral); font-weight: 800; }.ledger-state > span:empty { border: 3px solid var(--sona-line); border-top-color: var(--sona-coral); border-radius: 50%; background: transparent; animation: ledger-spin .8s linear infinite; }.ledger-state strong { color: #273246; font-size: 14px; }.ledger-state p { margin: 6px 0 0; color: #8a95a5; font-size: 10px; line-height: 1.6; }.ledger-state button { margin-top: 15px; padding: 9px 14px; border: 0; border-radius: 999px; background: var(--sona-coral); color: #fff; font: inherit; font-size: 10px; font-weight: 700; cursor: pointer; }.ledger-state--error > span { background: #fff0f0; color: #d84b4b; }
@keyframes ledger-spin { to { transform: rotate(360deg); } }

@media (min-width: 900px) {
    .ledger-page { padding-bottom: 0; background: #edf1f6; }.ledger-page .account-shell { max-width: 1440px; min-height: 100vh; flex-direction: row; background: #fff; box-shadow: 0 0 50px rgba(38,55,79,.07); }.ledger-page .sidebar { width: 255px; border-right-color: #e5eaf1; background: #f8fafc; }.main-panel--ledger { height: 100vh; overflow-y: auto; padding: 0 50px 70px; }.ledger-page .ledger-topbar { margin: 0 -50px 42px; padding: 12px 50px; }.ledger-intro { padding: 24px; }.ledger-page .ledger-row { min-height: 76px; padding: 16px 20px; }.ledger-page .ledger-row-label { font-size: 14px; }.ledger-page .ledger-amount { font-size: 15px; }
}

/* 輕量提示（見 app.js 的 showToast），取代原生 alert()。手機版浮在分頁列正上方
   （跟 .composer 同一個 bottom 偏移量），桌面版浮在畫面底部置中即可，沒有分頁列
   要閃避。opacity+transform 做淡入淡出，預設 pointer-events:none 不擋點擊。 */
.app-toast {
    position: fixed; left: 50%; bottom: calc(72px + env(safe-area-inset-bottom, 0px));
    transform: translate(-50%, 8px); max-width: calc(100% - 32px);
    background: rgba(30, 30, 34, 0.92); color: #fff; padding: 12px 18px; border-radius: 12px;
    font-size: 13px; line-height: 1.6; text-align: center; z-index: 50;
    opacity: 0; pointer-events: none; transition: opacity 0.2s ease, transform 0.2s ease;
}
.app-toast.visible { opacity: 1; transform: translate(-50%, 0); }
@media (min-width: 900px) {
    .app-toast { bottom: 32px; }
}

/* ============================================================
   登入／註冊入口（account.php 未登入狀態）
   訪客頁不使用 .shell、.sidebar 或 .tabbar，避免登入前出現角色分類。
   ============================================================ */
.auth-page {
    --auth-blue: var(--sona-coral);
    --auth-ink: #101828;
    --auth-muted: #687386;
    margin: 0; padding: 0; min-height: 100vh; background: #f7f9fc; color: var(--auth-ink);
}
.auth-layout { min-height: 100vh; display: grid; grid-template-columns: minmax(430px, 1.06fr) minmax(480px, .94fr); }
.auth-story {
    position: relative; overflow: hidden; min-height: 100vh; padding: 42px 54px 34px;
    display: flex; flex-direction: column; color: #fff;
    background: radial-gradient(circle at 78% 28%, rgba(60,137,255,.55), transparent 34%),
                radial-gradient(circle at 14% 82%, rgba(34,108,226,.35), transparent 35%),
                linear-gradient(145deg,#06142d 0%,#0a3378 54%,#135bc8 100%);
}
.auth-story::before { content: ""; position: absolute; inset: 0; opacity: .12; background-image: radial-gradient(#fff 1px,transparent 1px); background-size: 27px 27px; mask-image: linear-gradient(135deg,black,transparent 75%); }
.auth-story::after { content: ""; position: absolute; width: 560px; height: 560px; right: -280px; top: 20%; border: 1px solid rgba(255,255,255,.13); border-radius: 50%; box-shadow: 0 0 0 80px rgba(255,255,255,.025),0 0 0 160px rgba(255,255,255,.018); }
.auth-brand { position: relative; z-index: 2; width: fit-content; display: flex; align-items: center; gap: 11px; color: inherit; text-decoration: none; font-size: 20px; font-weight: 850; letter-spacing: -.03em; }
.auth-brand img { width: 39px; height: 39px; display: block; border-radius: 12px; box-shadow: 0 8px 22px rgba(0,0,0,.18); }
.auth-story-copy { position: relative; z-index: 2; max-width: 650px; margin: auto 0 35px; }
.auth-eyebrow { display: flex; align-items: center; gap: 9px; margin-bottom: 22px; color: #98c0ff; font-size: 10px; font-weight: 800; letter-spacing: .18em; }
.auth-eyebrow span { width: 28px; height: 1px; background: currentColor; }
.auth-story-copy h1 { margin: 0 0 25px; font-size: clamp(47px,5.3vw,73px); line-height: 1.08; letter-spacing: -.055em; }
.auth-story-copy h1 span { color: #80b2ff; }
.auth-story-copy p { max-width: 540px; margin: 0; color: #c8d8ef; font-size: 15px; line-height: 1.9; }
.auth-conversation { position: relative; z-index: 2; width: min(420px,80%); margin: 0 0 auto auto; padding: 18px; border: 1px solid rgba(255,255,255,.16); border-radius: 24px; background: rgba(255,255,255,.1); box-shadow: 0 24px 55px rgba(0,12,35,.24); backdrop-filter: blur(14px); transform: rotate(-1.5deg); }
.auth-conversation-head { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; }
.auth-conversation-head img { width: 37px; height: 37px; border-radius: 11px; }
.auth-conversation-head > div { display: flex; flex-direction: column; gap: 3px; }
.auth-conversation-head strong { font-size: 13px; }.auth-conversation-head span { display: flex; align-items: center; gap: 5px; color: #c4d7f3; font-size: 9px; }.auth-conversation-head i { width: 6px; height: 6px; border-radius: 50%; background: #4ade80; }
.auth-message { width: fit-content; max-width: 78%; padding: 10px 13px; border-radius: 14px; font-size: 11px; line-height: 1.55; }
.auth-message--left { background: rgba(255,255,255,.95); color: #344054; border-bottom-left-radius: 4px; }
.auth-message--right { margin: 10px 0 0 auto; background: #2779ef; color: #fff; border-bottom-right-radius: 4px; }
.auth-typing { display: flex; gap: 3px; width: fit-content; margin-top: 9px; padding: 9px 12px; border-radius: 13px; background: rgba(255,255,255,.13); }.auth-typing i { width: 4px; height: 4px; border-radius: 50%; background: #b9cee9; }
.auth-story-footer { position: relative; z-index: 2; margin-top: 35px; display: flex; align-items: center; justify-content: space-between; gap: 20px; color: #91a9ca; font-size: 9px; }
.auth-story-footer div { display: flex; gap: 18px; }.auth-story-footer a { color: inherit; text-decoration: none; }

.auth-panel-wrap { min-height: 100vh; display: flex; flex-direction: column; padding: 36px clamp(28px,5vw,72px); background: #fff; }
.auth-mobile-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 30px; }
.auth-mobile-head .auth-brand { color: var(--auth-ink); }.auth-home-link { color: #778195; text-decoration: none; font-size: 12px; font-weight: 650; }
.auth-panel { width: 100%; max-width: 440px; margin: auto; padding: 30px 0; }
.auth-panel-head { margin-bottom: 27px; }
.auth-panel-kicker { margin-bottom: 9px; color: var(--auth-blue); font-size: 10px; font-weight: 850; letter-spacing: .15em; text-transform: uppercase; }
.auth-panel-head h2 { margin: 0 0 10px; font-size: clamp(31px,3vw,40px); letter-spacing: -.045em; }
.auth-panel-head p { margin: 0; color: var(--auth-muted); font-size: 13px; line-height: 1.7; }
.auth-error { margin: 0 0 16px; padding: 11px 13px; border: 1px solid #fecaca; border-radius: 11px; background: #fff1f2; color: #b42318; font-size: 12px; line-height: 1.6; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; margin-bottom: 24px; padding: 4px; border-radius: 13px; background: #f0f3f7; }
.auth-tabs button { border: 0; padding: 10px 12px; border-radius: 10px; background: transparent; color: #7b8494; font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; }
.auth-tabs button.active { background: #fff; color: var(--auth-ink); box-shadow: 0 3px 10px rgba(42,58,82,.09); }
.auth-field { display: block; margin-bottom: 15px; }
.auth-field > span { display: block; margin: 0 0 7px; color: #344054; font-size: 11px; font-weight: 750; }
.auth-input-wrap { position: relative; }
.auth-input-icon { position: absolute; z-index: 1; left: 14px; top: 50%; transform: translateY(-50%); width: 20px; height: 20px; display: grid !important; place-items: center; margin: 0 !important; color: #98a2b3 !important; font-size: 11px !important; }
.auth-field input { width: 100%; min-height: 50px; margin: 0; padding: 12px 14px; border: 1px solid #dfe5ee; border-radius: 12px; outline: 0; background: #fbfcfe; color: var(--auth-ink); font: inherit; font-size: 16px; transition: border-color .2s ease, box-shadow .2s ease, background .2s ease; }
.auth-input-wrap input { padding-left: 44px; }
.auth-field input:focus { border-color: #70a5f5; background: #fff; box-shadow: 0 0 0 4px rgba(var(--sona-coral-rgb),.1); }
.auth-field input::placeholder { color: #a9b1bd; }
.auth-form-meta { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin: -2px 0 20px; color: #98a2b3; font-size: 10px; }
.auth-form-meta button { border: 0; padding: 4px 0; background: none; color: var(--auth-blue); font: inherit; font-size: 11px; font-weight: 750; cursor: pointer; }
.auth-submit { width: 100%; min-height: 52px; display: flex; align-items: center; justify-content: center; gap: 16px; border: 0; border-radius: 13px; background: var(--auth-blue); color: #fff; font: inherit; font-size: 14px; font-weight: 750; cursor: pointer; box-shadow: 0 12px 24px rgba(var(--sona-coral-rgb),.22); transition: transform .2s ease,box-shadow .2s ease; }
.auth-submit:hover { transform: translateY(-1px); box-shadow: 0 15px 29px rgba(var(--sona-coral-rgb),.28); }.auth-submit:disabled { opacity: .65; cursor: wait; transform: none; }
.auth-submit span { width: 24px; height: 24px; display: grid; place-items: center; border-radius: 50%; background: rgba(255,255,255,.15); font-size: 15px; }
.auth-text-button { width: 100%; margin-top: 10px; padding: 10px; border: 0; background: none; color: #7b8494; font: inherit; font-size: 12px; cursor: pointer; }
.auth-otp-step { text-align: center; }.auth-step-icon { width: 50px; height: 50px; margin: 3px auto 15px; display: grid; place-items: center; border-radius: 15px; background: var(--sona-surface); color: var(--auth-blue); font-size: 21px; }.auth-otp-step h3 { margin: 0 0 8px; font-size: 20px; }.auth-otp-step > p { max-width: 310px; margin: 0 auto 20px; color: var(--auth-muted); font-size: 12px; line-height: 1.7; }.auth-otp-step .auth-field { text-align: left; }
.auth-otp-input { padding-left: 14px !important; text-align: center; letter-spacing: .35em; font-size: 21px !important; font-variant-numeric: tabular-nums; }
.auth-forgot { position: relative; }.auth-back-button { width: 36px; height: 36px; margin-bottom: 24px; border: 1px solid #e1e7ef; border-radius: 50%; background: #fff; color: #344054; font-size: 17px; cursor: pointer; }
.auth-assurance { margin-top: 25px; padding-top: 19px; border-top: 1px solid #edf0f4; display: flex; align-items: center; justify-content: center; gap: 8px; color: #98a2b3; font-size: 10px; }.auth-assurance span { color: #5a96ee; font-size: 8px; }

/* ============================================================
   登入後角色目錄（app.php）
   ============================================================ */
.catalog-page { --catalog-blue:var(--sona-coral); --catalog-ink:#111827; --catalog-muted:#6b7586; background:#edf1f6; color:var(--catalog-ink); }
.catalog-shell { width: 100%; background: #fff; }
.main-panel--catalog-new { min-width: 0; background: #fff; }
.catalog-topbar { min-height: 70px; padding: 13px 18px; display: flex; align-items: center; gap: 16px; border-bottom: 1px solid #ebeff5; background: rgba(255,255,255,.94); }
.catalog-mobile-brand { display: flex; align-items: center; gap: 9px; color: var(--catalog-ink); text-decoration: none; font-size: 18px; font-weight: 850; }.catalog-mobile-brand img { width: 35px; height: 35px; border-radius: 11px; }
.catalog-topbar-copy { display: none; flex-direction: column; gap: 2px; }.catalog-topbar-copy span { color: #8c96a6; font-size: 8px; font-weight: 800; letter-spacing: .16em; }.catalog-topbar-copy strong { font-size: 13px; }
.catalog-actions { margin-left: auto; display: flex; gap: 7px; }.catalog-actions a { width: 36px; height: 36px; display: grid; place-items: center; border: 1px solid #e1e7f0; border-radius: 50%; color: #526074; text-decoration: none; font-style: normal; }.catalog-actions a span { font-size: 16px; }.catalog-actions em { display: none; font-style: normal; }
.catalog-scroll { padding: 34px 18px calc(90px + env(safe-area-inset-bottom,0px)); }
.catalog-intro { display: flex; flex-direction: column; gap: 24px; margin-bottom: 22px; }
.catalog-eyebrow { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; color: var(--catalog-blue); font-size: 9px; font-weight: 850; letter-spacing: .13em; }.catalog-eyebrow span { width: 22px; height: 1px; background: currentColor; }
.catalog-intro h1 { margin: 0 0 11px; font-size: clamp(31px,8.5vw,45px); line-height: 1.12; letter-spacing: -.045em; }.catalog-intro p { max-width: 520px; margin: 0; color: var(--catalog-muted); font-size: 12px; line-height: 1.7; }
.catalog-gender-switch { width: 100%; max-width: 360px; display: grid; grid-template-columns: 1fr 1fr; gap: 5px; padding: 4px; border-radius: 14px; background: #f0f3f7; }
.catalog-gender-switch a { min-height: 43px; display: flex; align-items: center; justify-content: center; gap: 8px; border-radius: 11px; color: #7a8494; text-decoration: none; font-size: 13px; font-weight: 750; }.catalog-gender-switch a.active { background: #fff; color: var(--catalog-blue); box-shadow: 0 4px 12px rgba(42,58,82,.09); }.catalog-gender-switch small { min-width: 20px; height: 20px; padding: 0 5px; display: grid; place-items: center; border-radius: 999px; background: #e2e7ef; color: #7c8798; font-size: 9px; }.catalog-gender-switch a.active small { background: #e9f1ff; color: var(--catalog-blue); }
.catalog-checkin { position: relative; overflow: hidden; margin: 0 0 34px; padding: 17px; display: flex; flex-wrap: wrap; align-items: center; gap: 12px; border: 1px solid var(--sona-line); border-radius: 18px; background: linear-gradient(120deg,#FFF6F2,#f8fbff); }
.catalog-checkin-icon { width: 38px; height: 38px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 12px; background: var(--catalog-blue); color: #fff; box-shadow: 0 8px 17px rgba(var(--sona-coral-rgb),.22); }.catalog-checkin .checkin-banner-text { position: relative; z-index: 2; flex: 1; min-width: 180px; }.catalog-checkin .checkin-banner-title { margin-bottom: 3px; font-size: 13px; }.catalog-checkin #checkinHint { color: #687a94; font-size: 10px; line-height: 1.5; }.catalog-checkin .checkin-banner-action { position: relative; z-index: 2; width: 100%; }.catalog-checkin-btn { border: 0; min-width: 92px; padding: 10px 15px; border-radius: 999px; background: var(--catalog-blue); color: #fff; font-size: 11px; font-weight: 750; cursor: pointer; box-shadow: 0 7px 16px rgba(var(--sona-coral-rgb),.18); }.catalog-checkin-btn:disabled { opacity: .62; cursor: default; box-shadow: none; }.catalog-checkin-challenge { display: flex; flex-direction: column; align-items: flex-start; gap: 5px; }.catalog-checkin-challenge[hidden] { display: none; }.catalog-checkin-challenge > span { color: #687a94; font-size: 9px; }.catalog-checkin[data-state="success"] { border-color: #cce8d7; background: linear-gradient(120deg,#effcf4,#fbfefc); }.catalog-checkin[data-state="success"] .catalog-checkin-icon { background: #239b57; box-shadow: 0 8px 17px rgba(35,155,87,.2); }.catalog-checkin-decoration { position: absolute; width: 145px; height: 145px; right: -75px; bottom: -92px; border: 1px solid rgba(var(--sona-coral-rgb),.14); border-radius: 50%; box-shadow: 0 0 0 26px rgba(var(--sona-coral-rgb),.025); }

/* Dashboard account check-in: strong contrast is intentional in all states. */
.catalog-checkin { border-color: #b8d3fb; background: linear-gradient(120deg, #e2efff, #FFF8F5); }
.catalog-checkin .checkin-banner-title { color: #102a4a; font-weight: 800; }
.catalog-checkin #checkinHint,
.catalog-checkin #dashboardCheckinHint { color: #405675; font-size: 11px; font-weight: 620; }
.catalog-checkin-btn { background: var(--sona-coral); color: #ffffff; box-shadow: 0 8px 18px rgba(var(--sona-coral-rgb),.28); }
.catalog-checkin-btn:hover { background: var(--sona-coral-deep); }
.catalog-checkin-btn:focus-visible { outline: 3px solid #8dbbff; outline-offset: 3px; }
.catalog-checkin-btn:disabled { opacity: 1; background: #8ea0bd; color: #ffffff; }
.catalog-section-head { margin-bottom: 15px; display: flex; align-items: end; justify-content: space-between; gap: 15px; }.catalog-section-head > div { display: flex; flex-direction: column; gap: 3px; }.catalog-section-head span { color: #98a2b3; font-size: 8px; font-weight: 800; letter-spacing: .15em; }.catalog-section-head h2 { margin: 0; font-size: 21px; letter-spacing: -.025em; }.catalog-section-head p { margin: 0; color: #98a2b3; font-size: 10px; }
.catalog-card-grid { padding: 0; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.catalog-character-card { min-width: 0; padding: 0; display: block; overflow: hidden; border: 1px solid #e5eaf1; border-radius: 18px; background: #fff; color: inherit; box-shadow: 0 8px 22px rgba(42,58,82,.055); transition: transform .25s ease,box-shadow .25s ease; }
.catalog-character-card:hover { transform: translateY(-4px); box-shadow: 0 15px 32px rgba(42,58,82,.11); }
.catalog-card-media { position: relative; overflow: hidden; aspect-ratio: 4 / 5; background: #edf2f8; }
.catalog-card-media .char-avatar { width: 100%; height: 100%; margin: 0; border-radius: 0; object-fit: cover; display: grid; place-items: center; font-size: 42px; transition: transform .4s ease; }.catalog-character-card:hover .catalog-card-media .char-avatar { transform: scale(1.025); }.catalog-card-media::after { content:""; position:absolute; inset:auto 0 0; height:45%; background:linear-gradient(transparent,rgba(5,15,31,.45)); pointer-events:none; }
.catalog-card-badge { position: absolute; z-index: 2; left: 10px; top: 10px; padding: 5px 7px; border: 1px solid rgba(255,255,255,.33); border-radius: 999px; background: rgba(10,25,48,.35); color: #fff; font-size: 7px; font-weight: 800; letter-spacing: .12em; backdrop-filter: blur(8px); }.catalog-card-open { position: absolute; z-index: 2; right: 10px; bottom: 10px; width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; background: rgba(255,255,255,.92); color: var(--catalog-blue); font-size: 13px; }
.catalog-card-body { padding: 13px; }.catalog-card-name-row h3 { margin: 0 0 4px; font-size: 17px; letter-spacing: -.02em; }.catalog-card-name-row > div > span { display: block; overflow: hidden; color: #818b9a; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }.catalog-character-card .char-tags { margin: 9px 0 0; display: flex; flex-wrap: wrap; gap: 4px; }.catalog-character-card .char-tags span { margin: 0; padding: 3px 6px; background: #f1f4f8; color: #697587; font-size: 8px; }.catalog-character-card .char-bio { display: none; }.catalog-card-cta { display: none; }

/* 共用側欄更新：資料切換的 class 與 JS 契約維持不變。 */
@media (min-width: 900px) {
    .sidebar-brand { padding: 22px 20px 18px; display: flex; align-items: center; gap: 10px; border-bottom: 1px solid #e8edf4; color: #111827; text-decoration: none; }.sidebar-brand img { width: 38px; height: 38px; border-radius: 12px; box-shadow: 0 7px 16px rgba(var(--sona-coral-rgb),.18); }.sidebar-brand > span { display: flex; flex-direction: column; gap: 2px; }.sidebar-brand strong { font-size: 17px; letter-spacing: -.02em; }.sidebar-brand small { color: #8a94a3; font-size: 9px; font-weight: 600; }
    .sidebar-heading-row { display: flex; align-items: center; justify-content: space-between; }.sidebar-heading-row > span { min-width: 23px; height: 20px; display: grid; place-items: center; border-radius: 999px; background: #edf1f6; color: #8590a0; font-size: 9px; }.sidebar-heading-row h2 { margin-bottom: 12px !important; }
    .sidebar-footer a { display: flex; align-items: center; gap: 9px; color: #657287; }.sidebar-footer a span { width: 21px; color: var(--sona-coral); font-size: 14px; text-align: center; }

    .catalog-page { padding-bottom: 0; }
    .catalog-shell { max-width: 1440px; min-height: 100vh; flex-direction: row; box-shadow: 0 0 50px rgba(38,55,79,.07); }
    .catalog-page .sidebar, .account-page .sidebar { width: 255px; border-right-color: #e5eaf1; background: #f8fafc; }
    .catalog-page .sidebar-header, .account-page .sidebar-header { padding: 19px 17px 12px; }
    .catalog-page .sidebar-tabs, .account-page .sidebar-tabs { padding: 4px; gap: 4px; border-radius: 12px; background: #e9edf3; }
    .catalog-page .sidebar-tabs button, .account-page .sidebar-tabs button { padding: 8px; border-radius: 9px; background: transparent; color: #7d8796; font-size: 11px; }
    .catalog-page .sidebar-tabs button.active, .account-page .sidebar-tabs button.active { background: #fff; color: var(--sona-coral); box-shadow: 0 3px 9px rgba(42,58,82,.09); }
    .catalog-page .sidebar-list, .account-page .sidebar-list { padding: 5px 11px 20px; }
    .catalog-page .sidebar-item, .account-page .sidebar-item { margin-bottom: 2px; padding: 8px 9px; border-radius: 11px; color: #526074; }.catalog-page .sidebar-item:hover, .account-page .sidebar-item:hover { background: #eef3fa; }.catalog-page .sidebar-item.active, .account-page .sidebar-item.active { background: #FFF0EB; color: var(--sona-coral-deep); }.catalog-page .sidebar-avatar, .account-page .sidebar-avatar { width: 34px; height: 34px; }.catalog-page .sidebar-name, .account-page .sidebar-name { font-size: 12px; }
    .catalog-page .sidebar-footer, .account-page .sidebar-footer { padding: 13px 16px 18px; border-top-color: #e5eaf1; gap: 10px; }
    .main-panel--catalog-new { height: 100vh; overflow: hidden; }
    .catalog-topbar { min-height: 72px; padding: 13px 34px; }.catalog-mobile-brand { display: none; }.catalog-topbar-copy { display: flex; }.catalog-actions a { width: auto; padding: 0 13px; display: flex; gap: 7px; border-radius: 999px; }.catalog-actions em { display: inline; font-size: 10px; font-weight: 700; }
    .catalog-scroll { height: calc(100vh - 72px); overflow-y: auto; padding: 54px clamp(35px,4.5vw,68px) 70px; }
    .catalog-intro { flex-direction: row; align-items: end; justify-content: space-between; margin-bottom: 29px; }.catalog-intro h1 { font-size: clamp(38px,4vw,55px); }.catalog-intro p { font-size: 13px; }.catalog-gender-switch { width: 280px; flex: 0 0 auto; }
    .catalog-checkin { padding: 17px 20px; margin-bottom: 45px; flex-wrap: nowrap; }.catalog-checkin .checkin-banner-action { width: auto; margin-left: auto; flex-direction: row; align-items: center; }.catalog-checkin-btn { white-space: nowrap; }
    .catalog-section-head { margin-bottom: 19px; }.catalog-section-head h2 { font-size: 25px; }
    .catalog-card-grid { grid-template-columns: repeat(3,minmax(0,1fr)); gap: 18px; }
    .catalog-card-media { aspect-ratio: 1 / .83; }.catalog-card-body { padding: 17px 17px 16px; }.catalog-card-name-row h3 { font-size: 19px; }.catalog-card-name-row > div > span { font-size: 10px; }.catalog-character-card .char-tags span { padding: 4px 7px; font-size: 8px; }.catalog-character-card .char-bio { display: -webkit-box; margin-top: 11px; min-height: 42px; font-size: 10px; line-height: 1.55; -webkit-line-clamp: 3; -webkit-box-orient: vertical; }.catalog-card-cta { margin-top: 14px; padding-top: 11px; border-top: 1px solid #edf0f4; display: flex; align-items: center; justify-content: space-between; color: #667285; font-size: 9px; font-weight: 700; }.catalog-card-cta span { color: var(--catalog-blue); font-size: 14px; }
}

@media (min-width: 1250px) {
    .catalog-card-grid { grid-template-columns: repeat(4,minmax(0,1fr)); }
}

/* ============================================================
   登入後帳號中心（account.php）
   ============================================================ */
.account-page { --account-blue:var(--sona-coral); --account-ink:#111827; --account-muted:#6b7586; background:#edf1f6; color:var(--account-ink); }
.main-panel--account { padding: 0 18px calc(90px + env(safe-area-inset-bottom,0px)); background: #fff; }
.account-topbar { min-height: 70px; margin: 0 -18px 28px; padding: 12px 18px; display: flex; align-items: center; gap: 13px; border-bottom: 1px solid #e8edf4; }.account-back { width: 35px; height: 35px; display: grid; place-items: center; border: 1px solid #e1e7ef; border-radius: 50%; color: #536075; text-decoration: none; font-size: 16px; }.account-topbar > div { display: flex; flex-direction: column; gap: 2px; }.account-topbar > div span { color: #929dac; font-size: 7px; font-weight: 850; letter-spacing: .16em; }.account-topbar h1 { margin: 0; font-size: 17px; }.account-home { margin-left: auto; color: var(--account-blue); text-decoration: none; font-size: 10px; font-weight: 700; }
.account-profile-card { position: relative; overflow: hidden; padding: 20px; display: flex; align-items: center; gap: 14px; border: 1px solid var(--sona-line); border-radius: 20px; background: linear-gradient(120deg,#FFF6F2,#fbfdff); }.account-profile-card::after { content:""; position:absolute; width:130px; height:130px; right:-75px; bottom:-85px; border:1px solid rgba(var(--sona-coral-rgb),.15); border-radius:50%; box-shadow:0 0 0 24px rgba(var(--sona-coral-rgb),.025); }.account-avatar { position:relative; width:52px; height:52px; flex:0 0 auto; display:grid; place-items:center; border-radius:16px; background:var(--account-blue); color:#fff; font-size:19px; font-weight:800; box-shadow:0 10px 20px rgba(var(--sona-coral-rgb),.22); }.account-avatar i { position:absolute; right:-2px; bottom:-2px; width:12px; height:12px; border:3px solid #FFF6F2; border-radius:50%; background:#22c55e; }.account-profile-copy { min-width:0; display:flex; flex-direction:column; gap:3px; }.account-profile-copy > span { color:#7d8999; font-size:9px; }.account-profile-copy strong { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:14px; }.account-profile-copy p { margin:1px 0 0; color:#738097; font-size:9px; line-height:1.5; }.account-status { display:none; position:relative; z-index:2; margin-left:auto; padding:6px 9px; align-items:center; gap:5px; border:1px solid #cee6d7; border-radius:999px; background:#f0fdf4; color:#16803c; font-size:8px; font-weight:700; }.account-status i { width:5px; height:5px; border-radius:50%; background:#22c55e; }
.account-section { margin-top: 34px; }.account-section-head { margin-bottom: 13px; display:flex; align-items:end; justify-content:space-between; gap:15px; }.account-section-head > div { display:flex; flex-direction:column; gap:2px; }.account-section-head span { color:#98a2b3; font-size:7px; font-weight:850; letter-spacing:.16em; }.account-section-head h2 { margin:0; font-size:19px; }.account-section-head > a { color:var(--account-blue); text-decoration:none; font-size:9px; font-weight:700; }
.account-wallet-card { overflow:hidden; border:1px solid #e2e7ef; border-radius:20px; background:#fff; box-shadow:0 9px 25px rgba(42,58,82,.05); }.account-plan-block { padding:20px; border-bottom:1px solid #edf0f4; background:#111827; color:#fff; }.account-plan-block > span { color:#9fabbb; font-size:9px; }.account-plan-block > strong { display:block; margin-top:5px; font-size:28px; letter-spacing:-.04em; }.account-plan-block p { margin:4px 0 0; color:#9fabbb; font-size:9px; }.account-balance-grid { display:grid; }.account-balance-grid > div { padding:17px 19px; display:flex; align-items:flex-start; gap:11px; }.account-balance-grid > div + div { border-top:1px solid #edf0f4; }.account-balance-icon { width:36px; height:36px; display:grid; place-items:center; flex:0 0 auto; border-radius:11px; background:var(--sona-surface); color:var(--account-blue); font-size:16px; }.account-balance-grid div div { display:flex; flex-direction:column; gap:3px; }.account-balance-grid small { color:#8490a1; font-size:9px; }.account-balance-grid strong { font-size:14px; }.account-balance-grid em { color:#98a2b3; font-size:8px; font-style:normal; }
.account-link-grid { display:grid; gap:10px; }.account-link-grid a { padding:15px; display:flex; align-items:center; gap:11px; border:1px solid #e2e7ef; border-radius:16px; color:inherit; text-decoration:none; background:#fff; }.account-link-icon { width:37px; height:37px; display:grid; place-items:center; flex:0 0 auto; border-radius:11px; background:#f0f4f9; color:var(--account-blue); }.account-link-grid a > div { min-width:0; display:flex; flex-direction:column; gap:3px; }.account-link-grid strong { font-size:12px; }.account-link-grid small { color:#8a94a3; font-size:9px; }.account-link-grid b { margin-left:auto; color:#a4acb8; font-size:14px; font-weight:400; }
.account-logout { width:100%; margin-top:34px; padding:13px; border:1px solid #fecaca; border-radius:13px; background:#fff; color:#d14343; font:inherit; font-size:11px; font-weight:700; cursor:pointer; }.account-logout:disabled { opacity:.6; cursor:wait; }

@media (min-width: 900px) {
    .account-page { padding-bottom:0; }.account-shell { max-width:1440px; min-height:100vh; flex-direction:row; box-shadow:0 0 50px rgba(38,55,79,.07); }.main-panel--account { height:100vh; overflow-y:auto; padding:0 clamp(40px,6vw,84px) 70px; }.account-topbar { margin:0 clamp(-84px,-6vw,-40px) 42px; padding:15px clamp(40px,6vw,84px); }.account-topbar h1 { font-size:20px; }.account-profile-card { padding:25px; }.account-avatar { width:62px; height:62px; border-radius:19px; font-size:22px; }.account-profile-copy strong { font-size:17px; }.account-profile-copy p { font-size:10px; }.account-status { display:flex; }.account-section { margin-top:40px; }.account-section-head h2 { font-size:22px; }.account-wallet-card { display:grid; grid-template-columns:.78fr 1.22fr; }.account-plan-block { border:0; border-right:1px solid #293345; padding:28px; }.account-balance-grid { grid-template-columns:1fr 1.25fr; }.account-balance-grid > div { padding:26px; }.account-balance-grid > div + div { border-top:0; border-left:1px solid #edf0f4; }.account-link-grid { grid-template-columns:1fr 1fr; }.account-link-grid a { padding:19px; }.account-logout { width:auto; min-width:190px; margin-top:42px; padding:12px 22px; }
}

/* 新版手機底部導覽：連結與 active 判斷維持原本 PHP 契約。 */
.tabbar { min-height: 64px; border-top-color:#e5eaf1; background:rgba(255,255,255,.96); backdrop-filter:blur(14px); }
.tabbar-item { position:relative; justify-content:center; gap:3px; padding:7px 0 6px; color:#9ba4b1; font-size:9px; }.tabbar-item.active { color:var(--sona-coral); }.tabbar-item.active::before { content:""; position:absolute; top:0; left:36%; right:36%; height:2px; border-radius:2px; background:var(--sona-coral); }.tabbar-icon { width:22px; height:22px; display:block; }.tabbar-icon svg { width:100%; height:100%; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }

@media (max-width: 899px) {
    .sidebar-brand { display:none; }
    .auth-layout { display:block; }.auth-story { display:none; }.auth-panel-wrap { min-height:100vh; padding:22px 20px 35px; }.auth-mobile-head { margin-bottom:38px; }.auth-mobile-head .auth-brand img { width:35px; height:35px; }.auth-mobile-head .auth-brand { font-size:18px; }.auth-panel { max-width:460px; padding:0; }.auth-panel-head h2 { font-size:34px; }.auth-assurance { margin-bottom:15px; }
    .catalog-page .shell, .account-page .shell { max-width:480px; min-height:calc(100vh - 64px); }.catalog-page, .account-page { padding-bottom:64px; }
}

/* ============================================================
   2026-08-08 對話流程：固定寬版殼、WhatsApp 式對話側欄與角色詳情。
   這一段刻意集中在檔案尾端，用頁面 class 限定作用範圍，避免影響舊功能。
   ============================================================ */
.entry-page { min-height:100vh; padding:24px; display:grid; place-items:center; background:radial-gradient(circle at 50% 12%,#FFF3EF 0,#f5f7fb 44%,#edf1f6 100%); color:#111827; }
.entry-card { width:min(380px,100%); padding:44px 28px; display:flex; flex-direction:column; align-items:center; border:1px solid rgba(219,228,241,.9); border-radius:28px; background:rgba(255,255,255,.94); box-shadow:0 25px 70px rgba(35,55,88,.12); text-align:center; }
.entry-card img { width:66px; height:66px; border-radius:20px; box-shadow:0 12px 28px rgba(var(--sona-coral-rgb),.2); }.entry-card h1 { margin:18px 0 8px; font-size:22px; letter-spacing:-.03em; }.entry-card p { margin:0; color:#7c8798; font-size:12px; }.entry-loader { width:22px; height:22px; margin-top:22px; border:2px solid var(--sona-line); border-top-color:var(--sona-coral); border-radius:50%; animation:entry-spin .8s linear infinite; }@keyframes entry-spin { to { transform:rotate(360deg); } }

.catalog-welcome { margin:0 0 26px; padding:15px 17px; display:flex; align-items:center; gap:13px; border:1px solid var(--sona-line); border-radius:17px; background:linear-gradient(110deg,#FFF6F2,#fbfdff); box-shadow:0 8px 22px rgba(var(--sona-coral-rgb),.06); }.catalog-welcome > span { width:36px; height:36px; display:grid; place-items:center; flex:0 0 auto; border-radius:11px; background:var(--sona-coral); color:#fff; }.catalog-welcome div { min-width:0; flex:1; }.catalog-welcome strong { display:block; margin-bottom:3px; font-size:13px; }.catalog-welcome p { margin:0; color:#738097; font-size:9px; line-height:1.55; }.catalog-welcome button { width:30px; height:30px; border:0; border-radius:50%; background:transparent; color:#8490a1; font-size:20px; cursor:pointer; }

.messenger-page { --messenger-blue:var(--sona-coral); --messenger-ink:#111827; --messenger-muted:#7d8999; padding-bottom:64px; overflow:hidden; background:#edf1f6; color:var(--messenger-ink); }.messenger-shell { width:100%; max-width:480px; min-height:calc(100dvh - 64px); height:calc(100dvh - 64px); background:#fff; }.conversation-sidebar { display:none; }
.main-panel--messages-home,.main-panel--chat-new { min-width:0; height:100%; overflow:hidden; background:#f7f9fc; }
.messenger-mobile-header { min-height:64px; padding:12px 17px; display:flex; align-items:center; justify-content:space-between; border-bottom:1px solid #e8edf3; background:#fff; }.messenger-mobile-header h1 { margin:0; font-size:22px; letter-spacing:-.03em; }.messenger-mobile-header a { width:36px; height:36px; display:grid; place-items:center; border-radius:50%; background:var(--sona-coral); color:#fff; text-decoration:none; font-size:22px; }
.messages-mobile-content { flex:1; min-height:0; overflow-y:auto; padding:25px 0 80px; background:#fff; }.messages-mobile-title { padding:0 17px 15px; }.messages-mobile-title span { color:var(--sona-coral); font-size:7px; font-weight:850; letter-spacing:.17em; }.messages-mobile-title h2 { margin:4px 0 0; font-size:20px; }.messages-page .messages-list { width:100%; max-width:none; margin:0; padding:0; border:0; border-radius:0; box-shadow:none; }.messages-page .message-row { min-height:78px; padding:12px 17px; display:flex; align-items:center; gap:12px; color:inherit; text-decoration:none; }.messages-page .message-row .char-avatar { width:52px !important; height:52px !important; }.messages-page .message-row-top { display:flex; align-items:center; gap:10px; }.messages-page .message-row-name { min-width:0; flex:1; font-size:14px; font-weight:750; }.messages-page .message-row time { color:#9aa4b2; font-size:9px; }.messages-page .message-row-preview { margin-top:4px; color:#8590a0; font-size:11px; }.messages-welcome { display:none; }

.chat-new-header { min-height:64px; padding:9px 13px; display:flex; align-items:center; gap:10px; flex:0 0 auto; border-bottom:1px solid #e6ebf2; background:rgba(255,255,255,.97); }.chat-mobile-back { width:30px; color:#526075; text-decoration:none; font-size:19px; }.chat-header-avatar { width:40px; height:40px; flex:0 0 auto; border-radius:50%; object-fit:cover; background:#e7effc; }.chat-header-avatar--fallback { display:grid; place-items:center; color:var(--sona-coral); font-weight:750; }.chat-header-avatar--fallback.female { background:#FFF0EB; color:var(--sona-coral-deep); }.chat-header-person { min-width:0; flex:1; }.chat-header-person h1 { margin:0 0 3px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:14px; }.chat-header-person span { display:flex; align-items:center; gap:5px; color:#7f8b9c; font-size:8px; }.chat-header-person i { width:6px; height:6px; border-radius:50%; background:#22c55e; box-shadow:0 0 0 2px #dcfce7; }.chat-new-header .header-actions { gap:4px; }.chat-new-header .call-icon-btn { width:34px; height:34px; padding:0; display:grid; place-items:center; border:1px solid #e2e7ef; border-radius:50%; background:#fff; color:#526075; text-decoration:none; font-size:14px; cursor:pointer; }
.chat-conversation-stage { min-height:0; flex:1; overflow:hidden; background:linear-gradient(rgba(247,249,252,.92),rgba(247,249,252,.92)),radial-gradient(#dbe3ef 1px,transparent 1px); background-size:auto,20px 20px; }.chat-new-messages { width:100%; height:100%; margin:0 auto; padding:22px 15px 30px; overflow-y:auto; }.chat-message-row { display:flex; align-items:flex-end; gap:7px; width:100%; }.chat-message-row.assistant { justify-content:flex-start; }.chat-message-row.user { justify-content:flex-end; }.chat-new-messages .bubble { max-width:min(82%,560px); padding:10px 13px; border-radius:15px; font-size:14px; box-shadow:0 2px 8px rgba(35,55,88,.04); }.chat-new-messages .bubble-content { display:block; overflow-wrap:anywhere; }.chat-new-messages .message-time { flex:0 0 auto; margin-bottom:4px; color:#8190a6; font-size:10px; line-height:1; font-variant-numeric:tabular-nums; white-space:nowrap; opacity:.9; }.chat-new-messages .bubble.assistant { border:1px solid #e8ecf2; border-bottom-left-radius:4px; background:#fff; }.chat-new-messages .bubble.user { border-bottom-right-radius:4px; background:var(--sona-coral); }
.chat-new-composer { position:relative; inset:auto; bottom:auto; width:100%; max-width:none; margin:0; padding:11px 13px; flex:0 0 auto; border-top:1px solid #e4e9f0; background:#fff; z-index:10; }.chat-new-composer input { min-width:0; min-height:43px; border:1px solid #e2e7ef; background:#f5f7fa; }.chat-new-composer button { width:42px; height:42px; background:var(--sona-coral); box-shadow:0 8px 16px rgba(var(--sona-coral-rgb),.2); }

.main-panel--character-new { min-width:0; padding:0 18px calc(92px + env(safe-area-inset-bottom,0px)); overflow-y:auto; background:#fff; }.character-new-topbar { min-height:70px; margin:0 -18px 28px; padding:12px 18px; display:flex; align-items:center; gap:13px; border-bottom:1px solid #e8edf4; background:#fff; }.character-new-topbar > div { display:flex; flex-direction:column; gap:2px; }.character-new-topbar > div span { color:#929dac; font-size:7px; font-weight:850; letter-spacing:.16em; }.character-new-topbar h1 { margin:0; font-size:17px; }
.character-new-card { width:100%; max-width:960px; margin:0 auto; overflow:hidden; border:1px solid #e0e6ee; border-radius:24px; background:#fff; box-shadow:0 18px 50px rgba(42,58,82,.08); }.character-new-media { position:relative; aspect-ratio:1/.82; overflow:hidden; background:#eef3f9; }.character-new-media img,.character-new-fallback { width:100%; height:100%; object-fit:cover; }.character-new-fallback { display:grid; place-items:center; background:#FFF0EB; color:var(--sona-coral); font-size:84px; font-weight:800; }.character-new-fallback.female { background:#FFF0EB; color:var(--sona-coral-deep); }.character-new-media > span { position:absolute; left:15px; bottom:15px; padding:6px 9px; border:1px solid rgba(255,255,255,.4); border-radius:999px; background:rgba(17,24,39,.7); color:#fff; font-size:7px; font-weight:850; letter-spacing:.13em; backdrop-filter:blur(8px); }.character-new-copy { padding:24px 21px 25px; }.character-new-status { display:flex; align-items:center; gap:7px; color:#6f7c8f; font-size:9px; font-weight:700; }.character-new-status i { width:7px; height:7px; border-radius:50%; background:#22c55e; }.character-new-copy h2 { margin:9px 0 4px; font-size:32px; letter-spacing:-.045em; }.character-new-tagline { margin:0; color:#758195; font-size:12px; }.character-new-tags { margin-top:16px; display:flex; flex-wrap:wrap; gap:6px; }.character-new-tags span { padding:6px 9px; border-radius:999px; background:#eff4fa; color:#65748a; font-size:9px; }.character-new-divider { height:1px; margin:23px 0; background:#edf0f4; }.character-new-copy h3 { margin:0 0 10px; font-size:13px; }.character-new-bio { color:#5f6b7c; font-size:12px; line-height:1.85; }.character-new-actions { margin-top:26px; display:grid; gap:9px; }.character-new-actions a { min-height:48px; display:flex; align-items:center; justify-content:center; border-radius:13px; text-decoration:none; font-size:12px; font-weight:750; }.character-chat-primary { gap:16px; background:var(--sona-coral); color:#fff; box-shadow:0 10px 23px rgba(var(--sona-coral-rgb),.2); }.character-chat-primary span { font-size:17px; }.character-chat-secondary { border:1px solid #dfe5ed; color:#566378; background:#fff; }

.account-recharge-btn { width:100%; margin-top:11px; padding:14px 16px; display:flex; align-items:center; gap:11px; border:1px dashed #F4B5A8; border-radius:16px; background:#FFF8F5; color:inherit; text-align:left; font:inherit; cursor:pointer; }.account-recharge-btn > span { width:37px; height:37px; display:grid; place-items:center; flex:0 0 auto; border-radius:11px; background:var(--sona-coral); color:#fff; font-size:18px; }.account-recharge-btn > div { min-width:0; display:flex; flex:1; flex-direction:column; gap:3px; }.account-recharge-btn strong { font-size:12px; }.account-recharge-btn small { color:#8190a4; font-size:9px; }.account-recharge-btn b { margin-left:auto; color:var(--sona-coral); font-size:8px; white-space:nowrap; }
.account-link-grid button { width:100%; padding:15px; display:flex; align-items:center; gap:11px; border:1px dashed #d6dde7; border-radius:16px; background:#fbfcfe; color:inherit; text-align:left; font:inherit; cursor:pointer; }.account-link-grid button > div { min-width:0; display:flex; flex:1; flex-direction:column; gap:3px; }.account-link-grid button b { margin-left:auto; color:#929dac; font-size:8px; font-weight:700; white-space:nowrap; }

@media (min-width:900px) {
    .messenger-page { padding-bottom:0; }.messenger-shell { max-width:1440px; min-height:100vh; height:100vh; flex-direction:row; box-shadow:0 0 50px rgba(38,55,79,.08); }
    .conversation-sidebar { width:350px; min-width:310px; display:flex; flex-direction:column; border-right:1px solid #dde4ed; background:#fff; }.conversation-sidebar-top { min-height:72px; padding:13px 17px; display:flex; align-items:center; border-bottom:1px solid #e8edf3; }.conversation-brand { display:flex; align-items:center; gap:10px; color:#111827; text-decoration:none; }.conversation-brand img { width:38px; height:38px; border-radius:12px; }.conversation-brand > span { display:flex; flex-direction:column; gap:2px; }.conversation-brand strong { font-size:15px; }.conversation-brand small { color:#8b96a6; font-size:8px; }.conversation-new { width:36px; height:36px; margin-left:auto; display:grid; place-items:center; border-radius:50%; background:var(--sona-coral); color:#fff; text-decoration:none; font-size:20px; }
    .conversation-sidebar-head { padding:22px 17px 13px; }.conversation-sidebar-head > div { display:flex; align-items:end; justify-content:space-between; margin-bottom:13px; }.conversation-sidebar-head > div span { color:var(--sona-coral); font-size:7px; font-weight:850; letter-spacing:.16em; }.conversation-sidebar-head h2 { margin:0; font-size:21px; }.conversation-search { height:39px; padding:0 12px; display:flex; align-items:center; gap:8px; border:1px solid #e2e7ee; border-radius:11px; background:#f6f8fb; color:#98a2b3; }.conversation-search input { min-width:0; flex:1; border:0; outline:0; background:transparent; font:inherit; font-size:11px; }.conversation-sidebar-list { min-height:0; flex:1; overflow-y:auto; padding:0 9px 12px; }.conversation-sidebar-item { min-height:72px; padding:9px; display:flex; align-items:center; gap:10px; border-radius:13px; color:inherit; text-decoration:none; }.conversation-sidebar-item:hover { background:#FFF8F5; }.conversation-sidebar-item.active { background:var(--sona-surface); }.conversation-sidebar-item > img,.conversation-avatar-fallback { width:46px; height:46px; flex:0 0 auto; border-radius:50%; object-fit:cover; }.conversation-avatar-fallback { display:grid; place-items:center; background:#FFF0EB; color:var(--sona-coral); font-weight:750; }.conversation-avatar-fallback.female { background:#FFF0EB; color:var(--sona-coral-deep); }.conversation-sidebar-copy { min-width:0; flex:1; display:flex; flex-direction:column; gap:4px; }.conversation-sidebar-copy strong { font-size:12px; }.conversation-sidebar-copy small { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; color:#8792a2; font-size:9px; }.conversation-sidebar-item time { align-self:flex-start; padding-top:4px; color:#a0a9b6; font-size:8px; }.conversation-sidebar-empty { height:100%; min-height:180px; padding:25px; display:flex; flex-direction:column; align-items:center; justify-content:center; text-align:center; color:#8792a2; }.conversation-sidebar-empty > span { font-size:25px; }.conversation-sidebar-empty strong { margin:8px 0; color:#445066; font-size:12px; }.conversation-sidebar-empty a { color:var(--sona-coral); font-size:9px; text-decoration:none; }.conversation-sidebar-loading { padding:22px; display:flex; justify-content:center; gap:5px; }.conversation-sidebar-loading i { width:6px; height:6px; border-radius:50%; background:#c5ceda; }
    .conversation-sidebar-nav { min-height:58px; padding:7px 10px; display:grid; grid-template-columns:repeat(3,1fr); border-top:1px solid #e7ecf2; }.conversation-sidebar-nav a { display:flex; flex-direction:column; align-items:center; justify-content:center; gap:3px; border-radius:10px; color:#8b96a5; text-decoration:none; font-size:7px; font-weight:700; }.conversation-sidebar-nav a span { font-size:14px; }.conversation-sidebar-nav a.active { color:var(--sona-coral); background:#f3f7fd; }
    .main-panel--messages-home,.main-panel--chat-new { height:100vh; }.messenger-mobile-header,.messages-mobile-content { display:none; }.messages-welcome { height:100%; display:flex; flex-direction:column; align-items:center; justify-content:center; padding:45px; text-align:center; }.messages-welcome-mark { width:76px; height:76px; margin-bottom:22px; padding:12px; border-radius:24px; background:#fff; box-shadow:0 16px 45px rgba(31,61,105,.13); }.messages-welcome-mark img { width:100%; height:100%; border-radius:15px; }.messages-welcome > span { color:var(--sona-coral); font-size:8px; font-weight:850; letter-spacing:.18em; }.messages-welcome h1 { margin:11px 0 12px; font-size:clamp(31px,4vw,48px); line-height:1.15; letter-spacing:-.045em; }.messages-welcome p { margin:0; color:#7e8999; font-size:11px; }.messages-welcome > a { margin-top:25px; padding:11px 16px; display:flex; align-items:center; gap:18px; border-radius:999px; background:var(--sona-coral); color:#fff; text-decoration:none; font-size:10px; font-weight:750; }
    .chat-new-header { min-height:72px; padding:11px 22px; }.chat-mobile-back { display:none; }.chat-header-avatar { width:44px; height:44px; }.chat-header-person h1 { font-size:15px; }.chat-new-header .header-actions { gap:7px; }.chat-new-header .call-icon-btn { width:38px; height:38px; }.chat-new-messages { max-width:820px; padding:32px 28px 42px; }.chat-new-messages .bubble { max-width:68%; font-size:13px; }.chat-new-composer { padding:14px max(22px,calc((100% - 820px)/2 + 28px)); }.chat-new-composer input { min-height:47px; }.chat-new-composer button { width:46px; height:46px; }
    .character-shell { max-width:1440px; }.main-panel--character-new { height:100vh; padding:0 clamp(40px,5vw,76px) 70px; }.character-new-topbar { margin:0 clamp(-76px,-5vw,-40px) 46px; padding:15px clamp(40px,5vw,76px); }.character-new-topbar h1 { font-size:20px; }.character-new-card { display:grid; grid-template-columns:minmax(300px,.9fr) minmax(390px,1.1fr); }.character-new-media { aspect-ratio:auto; min-height:590px; }.character-new-copy { padding:clamp(45px,6vw,78px); display:flex; flex-direction:column; justify-content:center; }.character-new-copy h2 { font-size:48px; }.character-new-bio { font-size:13px; }.character-new-actions { grid-template-columns:1.2fr .8fr; }.account-link-grid button { padding:19px; }
}

/* ============================================================
   暖橘品牌系統（2026-08-09）
   將各個既有頁面的冷灰／淡藍底色收斂為同一組奶油白、蜜桃與珊瑚色。
   保留綠色在線狀態、紅色錯誤等功能語意色，避免只為換色破壞可讀性。
   ============================================================ */
.home-body {
    --home-ink: var(--sona-ink);
    --home-muted: #80666B;
    --home-line: var(--sona-line);
    background: #FFF9F7;
}
.home-nav { border-bottom-color: rgba(255, 213, 204, .88); }
.home-brand-badge { box-shadow: 0 5px 14px rgba(var(--sona-coral-rgb), .22); }
.home-feature-card, .home-footer { background: #FFF9F7; }
.home-feature-card--dark { background: #3A1E25; border-color: #3A1E25; }
.home-footer-copy { border-top-color: var(--sona-line); color: #94767A; }

.catalog-page, .account-page, .messenger-page { background: #FFF7F4; }
.catalog-page { --catalog-ink: var(--sona-ink); --catalog-muted: #80666B; }
.account-page { --account-ink: var(--sona-ink); --account-muted: #80666B; }
.messenger-page { --messenger-ink: var(--sona-ink); --messenger-muted: #80666B; }
.catalog-gender-switch, .catalog-gender-switch small { background: #FFF0EB; }
.catalog-gender-switch a.active small { background: var(--sona-surface); }
.catalog-checkin { border-color: var(--sona-line); background: linear-gradient(120deg, #FFF3EF, #FFFDFB); }
.catalog-checkin .checkin-banner-title { color: var(--sona-ink); }
.catalog-checkin #checkinHint, .catalog-checkin #dashboardCheckinHint { color: #765D63; }
.catalog-checkin-btn:focus-visible { outline-color: var(--sona-peach); }
.catalog-character-card, .account-wallet-card, .account-link-grid a { border-color: var(--sona-line); box-shadow: 0 9px 25px rgba(113,52,58,.08); }
.catalog-card-media { background: var(--sona-surface); }
.catalog-character-card .char-tags span, .character-new-tags span { background: #FFF0EB; color: #765D63; }
.catalog-page .sidebar, .account-page .sidebar, .sidebar { background: #FFF9F7; border-color: var(--sona-line); }
.sidebar-brand { color: var(--sona-ink); border-bottom-color: var(--sona-line); }
.sidebar-heading-row > span { background: var(--sona-surface); color: #80666B; }
.catalog-page .sidebar-tabs, .account-page .sidebar-tabs { background: #FFF0EB; }
.catalog-page .sidebar-item:hover, .account-page .sidebar-item:hover { background: #FFF5F1; }
.catalog-page .sidebar-footer, .account-page .sidebar-footer { border-top-color: var(--sona-line); }

.account-profile-card { background: linear-gradient(120deg, #FFF3EF, #FFFDFB); }
.account-plan-block { background: #3A1E25; border-color: #F5D8D0; }
.account-plan-block > span, .account-plan-block p { color: #F4BDB1; }
.account-balance-grid > div + div { border-color: #F5D8D0; }
.account-link-icon { background: var(--sona-surface); }
.account-link-grid button { border-color: var(--sona-line); background: #FFF9F7; }

.entry-page { background: radial-gradient(circle at 50% 12%, #FFF3EF 0, #FFF8F5 44%, #FFEAE4 100%); color: var(--sona-ink); }
.entry-card { border-color: var(--sona-line); box-shadow: 0 25px 70px rgba(113,52,58,.12); }
.main-panel--messages-home, .main-panel--chat-new, .dashboard-explore { background: #FFF9F7; }
.conversation-sidebar { border-right-color: var(--sona-line); }
.conversation-sidebar-top, .messenger-mobile-header, .chat-new-header, .character-new-topbar, .account-topbar { border-color: var(--sona-line); }
.conversation-brand, .sidebar-brand { color: var(--sona-ink); }
.conversation-search { border-color: var(--sona-line); background: #FFF5F1; }
.conversation-sidebar-item:hover, .conversation-sidebar-nav a.active { background: var(--sona-surface); }
.chat-header-avatar { background: var(--sona-surface); }
.chat-new-header .call-icon-btn, .chat-new-composer input { border-color: var(--sona-line); }
.chat-new-composer input { background: #FFF5F1; }
.chat-conversation-stage { background: linear-gradient(rgba(255,249,247,.93),rgba(255,249,247,.93)), radial-gradient(#F6C9BF 1px, transparent 1px); background-size:auto,20px 20px; }
.chat-new-messages .bubble.assistant { border-color: var(--sona-line); }
.character-new-card { border-color: var(--sona-line); box-shadow: 0 18px 50px rgba(113,52,58,.10); }
.character-new-media { background: var(--sona-surface); }
.character-new-divider { background: var(--sona-line); }
.character-chat-secondary { border-color: var(--sona-line); color: #765D63; }
.home-legal-dialog iframe, .legal-body { background: #FFF9F7; }

@media (max-width:899px) {
    .messenger-page .tabbar { display:flex; }.chat-page .tabbar { display:flex; }.character-page .shell { max-width:480px; min-height:calc(100vh - 64px); }.character-page { padding-bottom:64px; }
}

/* 2026-08-08 中文介面字級與聊天設定按鈕微調。 */
.conversation-sidebar-head h2 { font-size:25px; line-height:1.25; letter-spacing:-.025em; }.conversation-brand strong { font-size:18px; line-height:1.3; }
.chat-new-header .header-actions { margin-left:auto; gap:9px; }.chat-new-header .chat-settings-action { border-radius:14px; border-color:#dce4ee; background:#f3f6fa; color:#46546a; box-shadow:0 5px 14px rgba(42,58,82,.07); }.chat-new-header .chat-settings-action svg { width:22px; height:22px; fill:none; stroke:currentColor; stroke-width:1.8; }.chat-new-header .chat-settings-action:hover { transform:translateY(-1px); border-color:#F4B5A8; background:#FFF3EF; color:var(--sona-coral); }

@media (min-width:900px) {
    .conversation-sidebar-nav a { font-size:12px; line-height:1.2; }.conversation-sidebar-nav a span { font-size:22px; }.conversation-sidebar-head { padding-top:24px; }.conversation-sidebar-head h2 { font-size:27px; }
    .account-profile-card { min-height:118px; padding:27px; }.account-profile-copy { gap:4px; overflow:visible; }.account-profile-copy > span { font-size:12px; line-height:1.5; }.account-profile-copy strong { padding:2px 0; overflow:visible; font-size:20px; line-height:1.4; text-overflow:clip; }.account-profile-copy p { margin-top:0; font-size:12px; line-height:1.65; }
}

@media (max-width:899px) {
    .messenger-mobile-header h1 { font-size:24px; }.messages-mobile-content { padding-top:10px; }
}

@media (max-width: 380px) {
    .catalog-scroll { padding-left:14px; padding-right:14px; }.catalog-card-grid { gap:9px; }.catalog-card-body { padding:10px; }.catalog-card-name-row h3 { font-size:15px; }.catalog-character-card .char-tags span:nth-child(n+3) { display:none; }
    .auth-panel-wrap { padding-left:16px; padding-right:16px; }
}

/* ============================================================
   首頁內嵌隱私政策：保留首頁上下文，不建立新分頁。
   ============================================================ */
.home-modal-open { overflow: hidden; }
.home-legal-modal[hidden] { display: none; }
.home-legal-modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 18px; }
.home-legal-backdrop { position: absolute; inset: 0; width: 100%; border: 0; background: rgba(10,18,31,.55); backdrop-filter: blur(7px); cursor: pointer; }
.home-legal-dialog { position: relative; width: min(900px,100%); height: min(86vh,900px); overflow: hidden; display: flex; flex-direction: column; border: 1px solid rgba(255,255,255,.7); border-radius: 24px; background: #fff; box-shadow: 0 35px 90px rgba(11,25,48,.28); }
.home-legal-dialog > header { min-height: 66px; padding: 12px 16px 12px 22px; display: flex; align-items: center; gap: 15px; border-bottom: 1px solid #e8edf4; background: rgba(255,255,255,.97); }
.home-legal-dialog > header > div { display: flex; flex-direction: column; gap: 2px; }.home-legal-dialog > header span { color: var(--sona-coral); font-size: 7px; font-weight: 850; letter-spacing: .16em; }.home-legal-dialog > header strong { color: #111827; font-size: 17px; }
.home-legal-close { width: 38px; height: 38px; margin-left: auto; border: 1px solid #e1e7ef; border-radius: 50%; background: #fff; color: #556176; font-size: 22px; line-height: 1; cursor: pointer; }
.home-legal-dialog iframe { width: 100%; min-height: 0; flex: 1; border: 0; background: #fafafa; }
.legal-body--embed { padding-bottom: 0; background: #fff; }.legal-body--embed .legal-shell { max-width: 760px; padding-top: 34px; }.legal-body--embed .legal-back { display: none; }.legal-body--embed .legal-header-row { justify-content: flex-end; margin-bottom: 18px; }

/* ============================================================
   我的消息：手機保留原本清單手感，桌面改為專用寬版資訊列表。
   ============================================================ */
.main-panel--messages { min-width: 0; background: #fff; }
.messages-desktop-head { display: none; }
.messages-list { padding: 6px 0 calc(82px + env(safe-area-inset-bottom,0px)); }
.messages-page .message-row { min-height: 70px; padding: 10px 16px; border-bottom: 1px solid #eef1f5; }
.messages-page .message-row > div { min-width: 0; flex: 1; }
.messages-page .message-row .char-avatar { width: 48px !important; height: 48px !important; margin: 0; flex: 0 0 auto; }
.messages-page .message-row-preview { max-width: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.message-row-arrow { display: none; margin-left: auto; color: #a7b0bd; font-size: 16px; }

/* ============================================================
   WhatsApp 連結：獨立版型，避免套用角色詳情頁 Grid。
   ============================================================ */
.main-panel--whatsapp { min-width: 0; padding: 0 18px calc(90px + env(safe-area-inset-bottom,0px)); background: #fff; }
.whatsapp-content { width: 100%; max-width: 760px; margin: 0 auto; }
.whatsapp-intro { margin-bottom: 20px; padding: 20px; display: flex; align-items: center; gap: 14px; border: 1px solid var(--sona-line); border-radius: 19px; background: linear-gradient(120deg,#FFF6F2,#fbfdff); }
.whatsapp-intro-icon { width: 46px; height: 46px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 14px; background: var(--sona-coral); color: #fff; font-size: 19px; box-shadow: 0 9px 19px rgba(var(--sona-coral-rgb),.2); }
.whatsapp-intro span { color: var(--sona-coral); font-size: 7px; font-weight: 850; letter-spacing: .16em; }.whatsapp-intro h2 { margin: 3px 0 5px; color: #111827; font-size: 18px; letter-spacing: -.02em; }.whatsapp-intro p { margin: 0; color: #738097; font-size: 10px; line-height: 1.55; }
.whatsapp-error { margin-bottom: 14px; border: 1px solid #f4caca; border-radius: 12px; }
.whatsapp-page .wa-panel { max-width: none; padding: 20px; border: 1px solid #e3e8ef; border-radius: 19px; background: #fff; box-shadow: 0 9px 25px rgba(42,58,82,.05); }
.wa-step-label { margin-bottom: 20px; display: flex; align-items: center; gap: 11px; }.wa-step-label > span { width: 34px; height: 34px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 11px; background: var(--sona-surface); color: var(--sona-coral); font-size: 12px; font-weight: 800; }.wa-step-label > div { display: flex; flex-direction: column; gap: 2px; }.wa-step-label strong { color: #1c2739; font-size: 13px; }.wa-step-label small { color: #8a95a5; font-size: 9px; }
.whatsapp-page .wa-label { margin-top: 15px; color: #465267; font-size: 11px; }.whatsapp-page .wa-hint { color: #8a95a5; font-size: 10px; line-height: 1.55; }.whatsapp-page .wa-panel input,.whatsapp-page .wa-panel select { min-height: 48px; border-color: #e0e5ec; background: #f8fafc; border-radius: 12px; }.whatsapp-page .wa-panel .btn-primary { min-height: 48px; border-radius: 12px; background: var(--sona-coral); font-size: 13px; box-shadow: 0 9px 20px rgba(var(--sona-coral-rgb),.18); }.whatsapp-page .wa-panel .btn-danger { background: #fff; color: #d14343; border: 1px solid #fecaca; box-shadow: none; }
.wa-panel--linked { text-align: center; }.wa-status-icon { width: 48px; height: 48px; margin: 0 auto 12px; display: grid; place-items: center; border-radius: 15px; background: #eaf9ef; color: #239b57; font-size: 20px; font-weight: 800; }.wa-panel--linked h3 { margin: 0 0 7px; font-size: 17px; }.wa-panel--linked p { max-width: 520px; margin: 0 auto 18px; color: #738097; font-size: 11px; line-height: 1.7; }

@media (min-width: 900px) {
    .messages-page .account-shell,.whatsapp-page .account-shell { max-width: 1440px; }
    .main-panel--messages { height: 100vh; overflow-y: auto; padding: 55px clamp(45px,5vw,72px) 70px; }.messages-page header.messages-mobile-top { display: none; }.messages-desktop-head { width: 100%; max-width: 920px; margin: 0 auto 28px; display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; }.messages-desktop-head > div > span { color: var(--sona-coral); font-size: 8px; font-weight: 850; letter-spacing: .16em; }.messages-desktop-head h1 { margin: 5px 0 7px; font-size: 35px; letter-spacing: -.035em; }.messages-desktop-head p { margin: 0; color: #7b8797; font-size: 12px; }.messages-desktop-head > a { display: inline-flex; align-items: center; gap: 8px; padding: 10px 14px; border: 1px solid #e0e6ee; border-radius: 999px; color: #516075; text-decoration: none; font-size: 10px; font-weight: 700; }.messages-desktop-head b { color: var(--sona-coral); font-size: 14px; }.messages-list { width: 100%; max-width: 920px; margin: 0 auto; padding: 0; overflow: hidden; border: 1px solid #e3e8ef; border-radius: 19px; background: #fff; box-shadow: 0 12px 32px rgba(42,58,82,.06); }.messages-page .message-row { min-height: 86px; padding: 14px 18px; gap: 14px; transition: background .2s ease; }.messages-page .message-row:hover { background: #FFF8F5; }.messages-page .message-row-name { font-size: 14px; }.messages-page .message-row-preview { margin-top: 4px; color: #8792a2; font-size: 11px; }.message-row-arrow { display: block; }
    .main-panel--whatsapp { height: 100vh; overflow-y: auto; padding: 0 clamp(45px,5vw,72px) 70px; }.whatsapp-page .whatsapp-topbar { margin: 0 clamp(-72px,-5vw,-45px) 42px; padding: 15px clamp(45px,5vw,72px); }.whatsapp-intro { padding: 24px; }.whatsapp-page .wa-panel { padding: 28px; }.whatsapp-page #phoneStep,.whatsapp-page #otpStep { max-width: 560px; }
}

@media (max-width: 899px) {
    .home-legal-modal { place-items: end center; padding: 0; }.home-legal-dialog { width: 100%; height: 92vh; border-radius: 24px 24px 0 0; }.home-legal-dialog > header { min-height: 61px; }.legal-body--embed .legal-shell { padding: 26px 20px 70px; }
    .messages-page .messages-empty { padding-top: 72px; }.whatsapp-page .account-topbar { margin-bottom: 22px; }
}

/* ============================================================
   2026-08-08 單頁消息工作區：左側導覽只切換右側，不再整頁跳轉。
   ============================================================ */
.dashboard-panel[hidden] { display:none !important; }
.dashboard-panel { min-width:0; width:100%; height:100%; }
.dashboard-panel--messages { min-height:0; display:flex; flex-direction:column; }
.dashboard-frame-panel { overflow:hidden; background:#fff; }
.dashboard-frame-panel iframe { width:100%; height:100%; display:block; border:0; background:#fff; }

.dashboard-explore { overflow-y:auto; padding:30px 18px 95px; background:#f7f9fc; }
.dashboard-panel-head { margin:0 auto 28px; max-width:1060px; display:flex; flex-direction:column; gap:18px; }.dashboard-panel-head > div > span { color:var(--sona-coral); font-size:8px; font-weight:850; letter-spacing:.18em; }.dashboard-panel-head h1 { margin:6px 0 7px; font-size:31px; letter-spacing:-.04em; }.dashboard-panel-head p { margin:0; color:#7d8999; font-size:11px; line-height:1.6; }.dashboard-character-search { width:100%; height:45px; padding:0 14px; display:flex; align-items:center; gap:9px; border:1px solid #dfe5ed; border-radius:13px; background:#fff; color:#98a2b3; }.dashboard-character-search input { min-width:0; flex:1; border:0; outline:0; background:transparent; font:inherit; font-size:16px; }
.dashboard-world-filter { max-width:1060px; margin:0 auto 23px; display:flex; gap:8px; overflow-x:auto; padding:2px 1px 9px; scrollbar-width:none; }.dashboard-world-filter::-webkit-scrollbar { display:none; }.dashboard-world-filter button,.dashboard-world-empty button { flex:0 0 auto; border:1px solid #dce5ef; border-radius:999px; background:#fff; color:#647286; font:700 10px/1 inherit; cursor:pointer; padding:10px 13px; transition:.18s ease; }.dashboard-world-filter button:hover { border-color:#F4B5A8; color:var(--sona-coral); }.dashboard-world-filter button.active { border-color:var(--sona-coral); background:var(--sona-coral); color:#fff; box-shadow:0 7px 16px rgba(var(--sona-coral-rgb),.18); }.dashboard-world-filter small { margin-left:4px; font-size:8px; opacity:.78; }.dashboard-world-empty { max-width:680px; margin:7vh auto 0; padding:36px 26px; display:flex; flex-direction:column; align-items:center; text-align:center; border:1px solid var(--sona-line); border-radius:25px; background:linear-gradient(140deg,#fff,#FFF6F2); box-shadow:0 16px 42px rgba(25,65,116,.08); }.dashboard-world-empty > span { width:48px; height:48px; display:grid; place-items:center; margin-bottom:13px; border-radius:16px; background:var(--sona-coral); color:#fff; box-shadow:0 9px 21px rgba(var(--sona-coral-rgb),.22); }.dashboard-world-empty strong { font-size:18px; }.dashboard-world-empty p { max-width:330px; margin:8px 0 18px; color:#7b8798; font-size:11px; line-height:1.7; }.dashboard-world-empty button { border-color:var(--sona-coral); background:var(--sona-coral); color:#fff; }
.dashboard-character-group { max-width:1060px; margin:0 auto 34px; }.dashboard-character-group-head { margin-bottom:13px; display:flex; align-items:center; justify-content:space-between; }.dashboard-character-group-head h2 { margin:0; font-size:18px; }.dashboard-character-group-head span { padding:5px 8px; border-radius:999px; background:#e9eef5; color:#7f8a9a; font-size:8px; }.dashboard-character-grid { display:grid; grid-template-columns:1fr; gap:9px; }.dashboard-character-card { width:100%; min-width:0; padding:10px; display:flex; align-items:center; gap:11px; border:1px solid #e2e7ee; border-radius:15px; background:#fff; color:inherit; text-align:left; font:inherit; cursor:pointer; transition:transform .18s ease,border-color .18s ease,box-shadow .18s ease; }.dashboard-character-card:hover { transform:translateY(-2px); border-color:#F4B5A8; box-shadow:0 10px 25px rgba(42,58,82,.08); }.dashboard-character-card > img,.dashboard-character-fallback { width:54px; height:54px; flex:0 0 auto; border-radius:14px; object-fit:cover; }.dashboard-character-fallback { display:grid; place-items:center; background:#FFF0EB; color:var(--sona-coral); font-size:19px; font-weight:800; }.dashboard-character-fallback.female { background:#FFF0EB; color:var(--sona-coral-deep); }.dashboard-character-copy { min-width:0; flex:1; display:flex; flex-direction:column; gap:3px; }.dashboard-character-copy strong { font-size:13px; }.dashboard-character-copy small { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; color:#7d8999; font-size:9px; }.dashboard-character-copy em { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; color:var(--sona-coral); font-size:8px; font-style:normal; }.dashboard-character-card > b { color:var(--sona-coral); font-size:16px; font-weight:500; }

.chat-avatar-button { width:44px; height:44px; padding:0; flex:0 0 auto; display:grid; place-items:center; overflow:hidden; border:2px solid #fff; border-radius:50%; background:transparent; box-shadow:0 0 0 1px #dbe3ee,0 5px 14px rgba(42,58,82,.1); cursor:pointer; }.chat-avatar-button .chat-header-avatar { width:100%; height:100%; }.chat-avatar-button:hover { box-shadow:0 0 0 2px rgba(var(--sona-coral-rgb),.25),0 7px 17px rgba(42,58,82,.13); }
.chat-new-header .call-icon-btn { width:42px; height:42px; }.chat-new-header .call-icon-btn svg { width:21px; height:21px; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }.chat-new-header .call-phone-action { border-color:var(--sona-coral); background:var(--sona-coral); color:#fff; box-shadow:0 8px 18px rgba(var(--sona-coral-rgb),.22); }.chat-new-header .call-phone-action svg { fill:currentColor; stroke:none; }.chat-new-header .chat-settings-action:hover { border-color:#F4B5A8; background:#FFF7F4; color:var(--sona-coral); }
.chat-intro-open { overflow:hidden; }.chat-intro-modal[hidden] { display:none; }.chat-intro-modal { position:fixed; inset:0; z-index:80; display:grid; place-items:center; padding:18px; }.chat-intro-backdrop { position:absolute; inset:0; width:100%; height:100%; border:0; background:rgba(10,18,31,.54); backdrop-filter:blur(7px); cursor:pointer; }.chat-intro-dialog { position:relative; width:min(480px,100%); max-height:min(760px,88vh); overflow-y:auto; border:1px solid rgba(255,255,255,.75); border-radius:25px; background:#fff; box-shadow:0 30px 90px rgba(11,25,48,.3); }.chat-intro-dialog > img { width:100%; height:230px; display:block; object-fit:cover; }.chat-intro-close { position:absolute; z-index:2; top:13px; right:13px; width:38px; height:38px; display:grid; place-items:center; border:1px solid rgba(255,255,255,.6); border-radius:50%; background:rgba(17,24,39,.58); color:#fff; font-size:22px; cursor:pointer; backdrop-filter:blur(7px); }.chat-intro-content { padding:25px; }.chat-intro-content > span { display:flex; align-items:center; gap:7px; color:#7a8798; font-size:9px; }.chat-intro-content > span i { width:7px; height:7px; border-radius:50%; background:#22c55e; }.chat-intro-content h2 { margin:8px 0 4px; font-size:31px; letter-spacing:-.04em; }.chat-intro-tagline { margin:0; color:#718095; font-size:12px; }.chat-intro-tags { margin:15px 0 19px; display:flex; flex-wrap:wrap; gap:6px; }.chat-intro-tags em { padding:6px 9px; border-radius:999px; background:#edf3fb; color:var(--sona-coral); font-size:9px; font-style:normal; }.chat-intro-bio { margin:0; color:#5d6a7b; font-size:11px; line-height:1.8; }

.chat-embed-page { padding:0; background:#fff; }.chat-embed-page .messenger-shell { width:100%; max-width:none; min-height:100vh; height:100vh; margin:0; box-shadow:none; }.chat-embed-page .main-panel--chat-new { width:100%; height:100vh; }.chat-embed-page .chat-mobile-back { display:none; }
.dashboard-embed-page { padding:0 !important; background:#fff; }.dashboard-embed-page .account-shell { width:100%; max-width:none !important; min-height:100vh !important; margin:0; box-shadow:none; }.dashboard-embed-page .main-panel--account { width:100%; height:100vh; }.dashboard-embed-page .main-panel--account > .account-profile-card, .dashboard-embed-page .main-panel--account > .account-section, .dashboard-embed-page .main-panel--account > .account-logout { width:min(860px,100%); margin-left:auto; margin-right:auto; }.dashboard-embed-page .account-back,.dashboard-embed-page .account-home { display:none; }
.settings-embed-page { padding:0; background:#fff; }.settings-embed-page .settings-shell { width:100%; max-width:none; min-height:100vh; margin:0; box-shadow:none; }.settings-embed-page .main-panel--settings { width:100%; min-width:0; height:100vh; overflow-y:auto; }.settings-embed-page .main-panel--settings > * { max-width:760px; }

@media (min-width:600px) {
    .dashboard-character-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
}

@media (min-width:900px) {
    .conversation-sidebar-top { min-height:78px; padding:15px 18px; }.conversation-new { width:44px; height:44px; font-size:24px; }
    .conversation-sidebar-nav { min-height:82px; padding:8px 9px; gap:5px; }.conversation-sidebar-nav a { gap:5px; font-size:10px; border:1px solid transparent; }.conversation-sidebar-nav a span { font-size:20px; }.conversation-sidebar-nav a:hover { border-color:#dfe7f2; background:#f7f9fc; color:#536176; }.conversation-sidebar-nav a.active { border-color:#d8e6fa; }
    .dashboard-explore { padding:48px clamp(32px,4vw,60px) 70px; }.dashboard-panel-head { flex-direction:row; align-items:end; justify-content:space-between; }.dashboard-panel-head h1 { font-size:40px; }.dashboard-character-search { width:280px; flex:0 0 auto; }.dashboard-character-search input { font-size:11px; }.dashboard-character-grid { grid-template-columns:repeat(3,minmax(0,1fr)); }.dashboard-character-card { padding:12px; }.dashboard-character-card > img,.dashboard-character-fallback { width:58px; height:58px; }
    .chat-new-header .call-icon-btn { width:46px; height:46px; }.chat-new-header .call-icon-btn svg { width:23px; height:23px; }.chat-avatar-button { width:48px; height:48px; }
    .dashboard-embed-page .main-panel--account { padding-left:clamp(36px,5vw,72px); padding-right:clamp(36px,5vw,72px); }.dashboard-embed-page .account-topbar { margin-left:clamp(-72px,-5vw,-36px); margin-right:clamp(-72px,-5vw,-36px); padding-left:clamp(36px,5vw,72px); padding-right:clamp(36px,5vw,72px); }
}

@media (max-width:899px) {
    .main-panel--messages-home { height:calc(100dvh - 64px); }.dashboard-panel { height:calc(100dvh - 128px); }.dashboard-panel--messages { min-height:0; }.dashboard-panel--messages .messages-mobile-content { height:100%; }.dashboard-explore { padding-top:25px; }.dashboard-frame-panel { height:calc(100dvh - 128px); }
    .chat-new-header .header-actions { gap:6px; }.chat-new-header .call-icon-btn { width:44px; height:44px; }.chat-avatar-button { width:44px; height:44px; }.chat-intro-modal { place-items:end center; padding:0; }.chat-intro-dialog { width:100%; max-height:86vh; border-radius:24px 24px 0 0; }.chat-intro-dialog > img { height:210px; }
    .chat-embed-page .main-panel--chat-new,.chat-embed-page .messenger-shell { height:100vh; min-height:100vh; }.chat-embed-page .main-panel--chat-new { max-width:none; }.chat-embed-page .chat-new-composer { bottom:0; }
    .dashboard-embed-page .account-shell { min-height:100vh !important; }.dashboard-embed-page .main-panel--account { height:100vh; padding-bottom:45px; }.settings-embed-page .settings-shell { min-height:100vh; }.settings-embed-page .main-panel--settings { height:100vh; }
}

/* 最終覆寫放在單頁工作區規則之後，確保中英文標題與控制按鈕尺寸一致。 */
.conversation-sidebar-head h2 { font-size:25px; line-height:1.25; letter-spacing:-.025em; }.conversation-brand strong { font-size:18px; line-height:1.3; }
.chat-new-header .header-actions { margin-left:auto; gap:9px; }.chat-new-header .chat-settings-action { border-radius:14px; border-color:#dce4ee; background:#f3f6fa; color:#46546a; box-shadow:0 5px 14px rgba(42,58,82,.07); }.chat-new-header .chat-settings-action svg { width:22px; height:22px; fill:none; stroke:currentColor; stroke-width:1.8; }.chat-new-header .chat-settings-action:hover { transform:translateY(-1px); border-color:#F4B5A8; background:#FFF3EF; color:var(--sona-coral); }

@media (min-width:900px) {
    .conversation-sidebar-nav a { font-size:12px; line-height:1.2; }.conversation-sidebar-nav a span { font-size:22px; }.conversation-sidebar-head { padding-top:24px; }.conversation-sidebar-head h2 { font-size:27px; }
}

@media (max-width:899px) {
    .messenger-mobile-header h1 { font-size:24px; }.messages-mobile-content { padding-top:10px; }.chat-new-header .header-actions { gap:8px; }
}

.account-balance-grid em + em { margin-top:1px; }.account-balance-grid #walletText { font-variant-numeric:tabular-nums; }

.account-checkin-control { position:relative; z-index:2; margin-left:auto; display:flex; flex-direction:column; align-items:flex-end; gap:7px; }
.account-checkin-btn { min-width:98px; border:0; padding:9px 13px; border-radius:999px; background:var(--sona-coral); color:#fff; font:700 10px/1.2 inherit; cursor:pointer; box-shadow:0 8px 17px rgba(var(--sona-coral-rgb),.2); }
.account-checkin-btn:disabled { background:#8ea0bd; cursor:default; box-shadow:none; }
.account-checkin-challenge { width:min(300px,72vw); padding:9px; border:1px solid var(--sona-line); border-radius:12px; background:#fff; box-shadow:0 10px 25px rgba(42,58,82,.1); }
.account-checkin-challenge[hidden] { display:none; }
.account-checkin-challenge > span { display:block; margin-top:5px; color:#687a94; font-size:9px; }

.dashboard-character-intro-open { overflow:hidden; }
.dashboard-character-intro-modal[hidden] { display:none; }
.dashboard-character-intro-modal { position:fixed; z-index:90; inset:0; display:grid; place-items:center; padding:18px; }
.dashboard-character-intro-backdrop { position:absolute; inset:0; width:100%; height:100%; border:0; background:rgba(10,18,31,.54); backdrop-filter:blur(7px); cursor:pointer; }
.dashboard-character-intro-dialog { position:relative; width:min(500px,100%); max-height:min(790px,90vh); overflow-y:auto; border:1px solid rgba(255,255,255,.75); border-radius:25px; background:#fff; box-shadow:0 30px 90px rgba(11,25,48,.3); }
.dashboard-character-intro-dialog > img,.dashboard-character-intro-fallback { width:100%; height:min(48vh,460px); min-height:250px; display:block; object-fit:contain; object-position:center top; background:var(--sona-surface); }
.dashboard-character-intro-dialog > img[hidden],.dashboard-character-intro-fallback[hidden] { display:none; }
.dashboard-character-intro-fallback { display:grid; place-items:center; color:var(--sona-coral); font-size:76px; font-weight:800; }.dashboard-character-intro-fallback.female { background:#FFF0EB; color:var(--sona-coral-deep); }
.dashboard-character-intro-close { position:absolute; z-index:2; top:13px; right:13px; width:38px; height:38px; display:grid; place-items:center; border:1px solid rgba(255,255,255,.6); border-radius:50%; background:rgba(17,24,39,.58); color:#fff; font-size:22px; cursor:pointer; backdrop-filter:blur(7px); }
.dashboard-character-intro-copy { padding:25px; }.dashboard-character-intro-copy > span { display:flex; align-items:center; gap:7px; color:#7a8798; font-size:9px; }.dashboard-character-intro-copy > span i { width:7px; height:7px; border-radius:50%; background:#22c55e; }.dashboard-character-intro-copy h2 { margin:8px 0 4px; font-size:31px; letter-spacing:-.04em; }.dashboard-character-intro-copy > p { margin:0; color:#65748a; font-size:12px; line-height:1.8; }.dashboard-character-intro-copy #dashboardCharacterIntroTagline { color:#718095; }.dashboard-character-intro-copy #dashboardCharacterIntroTags { margin:15px 0 19px; display:flex; flex-wrap:wrap; gap:6px; }.dashboard-character-intro-copy #dashboardCharacterIntroTags em { padding:6px 9px; border-radius:999px; background:#edf3fb; color:var(--sona-coral); font-size:9px; font-style:normal; }.dashboard-character-intro-copy #dashboardCharacterIntroStart { width:100%; min-height:48px; margin-top:24px; display:flex; align-items:center; justify-content:center; gap:16px; border:0; border-radius:13px; background:var(--sona-coral); color:#fff; font:750 12px/1 inherit; cursor:pointer; box-shadow:0 10px 23px rgba(var(--sona-coral-rgb),.2); }.dashboard-character-intro-copy #dashboardCharacterIntroStart b { font-size:17px; }

/* Dashboard state must beat the explicit flex layout above. Without this rule an
   unavailable-world notice remained visible behind the active Asia catalog. */
.dashboard-world-empty[hidden] { display:none !important; }

/* Explore cards intentionally use the established portrait-first catalog pattern:
   a consistent crop above concise details, rather than stretching an avatar next
   to a long paragraph. */
.dashboard-character-card { display:block; overflow:hidden; padding:0; border-radius:18px; }
.dashboard-character-card > img { width:100%; height:auto; aspect-ratio:4 / 3; display:block; border-radius:0; object-fit:cover; }
.dashboard-character-card > .dashboard-character-fallback { width:100%; height:auto; aspect-ratio:4 / 3; border-radius:0; }
.dashboard-character-copy { min-height:104px; padding:14px 15px 16px; gap:5px; }
.dashboard-character-copy strong { font-size:16px; }
.dashboard-character-copy small { font-size:10px; }
.dashboard-character-copy em { font-size:9px; white-space:normal; line-height:1.45; }
.dashboard-character-copy i { display:-webkit-box; overflow:hidden; margin-top:3px; color:#718095; font-size:10px; line-height:1.55; font-style:normal; -webkit-line-clamp:2; -webkit-box-orient:vertical; }
.dashboard-character-card > b { display:none; }

/* Desktop workspace should fill the browser instead of being centered in a
   1440px canvas with grey gutters on wide displays. */
@media (min-width:900px) {
    .messenger-shell { max-width:none; margin:0; }
}

/* The ledger is a child of the account panel, so its back action remains in
   that panel rather than escaping to a full standalone account page. */
.dashboard-embed-page.ledger-page .account-back { display:grid; }

/* Final warm-brand overrides: kept at file end so older layout compatibility
   rules cannot reintroduce the legacy cold-blue surfaces. */
.home-body { --home-ink:var(--sona-ink); --home-muted:#80666B; --home-line:var(--sona-line); background:#FFF9F7; }
.home-nav { border-bottom-color:rgba(255,213,204,.88); }.home-brand-badge { box-shadow:0 5px 14px rgba(var(--sona-coral-rgb),.22); }.home-feature-card,.home-footer { background:#FFF9F7; }.home-feature-card--dark { background:#3A1E25; border-color:#3A1E25; }.home-footer-copy { border-top-color:var(--sona-line); color:#94767A; }
.catalog-page,.account-page,.messenger-page { background:#FFF7F4; }.catalog-page { --catalog-ink:var(--sona-ink); --catalog-muted:#80666B; }.account-page { --account-ink:var(--sona-ink); --account-muted:#80666B; }.messenger-page { --messenger-ink:var(--sona-ink); --messenger-muted:#80666B; }
.catalog-gender-switch,.catalog-gender-switch small { background:#FFF0EB; }.catalog-gender-switch a.active small { background:var(--sona-surface); }.catalog-checkin { border-color:var(--sona-line); background:linear-gradient(120deg,#FFF3EF,#FFFDFB); }.catalog-checkin .checkin-banner-title { color:var(--sona-ink); }.catalog-checkin #checkinHint,.catalog-checkin #dashboardCheckinHint { color:#765D63; }.catalog-checkin-btn:focus-visible { outline-color:var(--sona-peach); }
.catalog-character-card,.account-wallet-card,.account-link-grid a { border-color:var(--sona-line); box-shadow:0 9px 25px rgba(113,52,58,.08); }.catalog-card-media { background:var(--sona-surface); }.catalog-character-card .char-tags span,.character-new-tags span { background:#FFF0EB; color:#765D63; }.catalog-page .sidebar,.account-page .sidebar,.sidebar { background:#FFF9F7; border-color:var(--sona-line); }.sidebar-brand { color:var(--sona-ink); border-bottom-color:var(--sona-line); }.sidebar-heading-row > span { background:var(--sona-surface); color:#80666B; }.catalog-page .sidebar-tabs,.account-page .sidebar-tabs { background:#FFF0EB; }.catalog-page .sidebar-item:hover,.account-page .sidebar-item:hover { background:#FFF5F1; }.catalog-page .sidebar-footer,.account-page .sidebar-footer { border-top-color:var(--sona-line); }
.account-profile-card { background:linear-gradient(120deg,#FFF3EF,#FFFDFB); }.account-plan-block { background:#3A1E25; border-color:#F5D8D0; }.account-plan-block > span,.account-plan-block p { color:#F4BDB1; }.account-balance-grid > div + div { border-color:#F5D8D0; }.account-link-icon { background:var(--sona-surface); }.account-link-grid button { border-color:var(--sona-line); background:#FFF9F7; }
.entry-page { background:radial-gradient(circle at 50% 12%,#FFF3EF 0,#FFF8F5 44%,#FFEAE4 100%); color:var(--sona-ink); }.entry-card { border-color:var(--sona-line); box-shadow:0 25px 70px rgba(113,52,58,.12); }.main-panel--messages-home,.main-panel--chat-new,.dashboard-explore { background:#FFF9F7; }.conversation-sidebar { border-right-color:var(--sona-line); }.conversation-sidebar-top,.messenger-mobile-header,.chat-new-header,.character-new-topbar,.account-topbar { border-color:var(--sona-line); }.conversation-brand,.sidebar-brand { color:var(--sona-ink); }.conversation-search { border-color:var(--sona-line); background:#FFF5F1; }.conversation-sidebar-item:hover,.conversation-sidebar-nav a.active { background:var(--sona-surface); }
.chat-header-avatar { background:var(--sona-surface); }.chat-new-header .call-icon-btn,.chat-new-composer input { border-color:var(--sona-line); }.chat-new-composer input { background:#FFF5F1; }.chat-conversation-stage { background:linear-gradient(rgba(255,249,247,.93),rgba(255,249,247,.93)),radial-gradient(#F6C9BF 1px,transparent 1px); background-size:auto,20px 20px; }.chat-new-messages .bubble.assistant { border-color:var(--sona-line); }.character-new-card { border-color:var(--sona-line); box-shadow:0 18px 50px rgba(113,52,58,.10); }.character-new-media { background:var(--sona-surface); }.character-new-divider { background:var(--sona-line); }.character-chat-secondary { border-color:var(--sona-line); color:#765D63; }.home-legal-dialog iframe,.legal-body { background:#FFF9F7; }
.home-hero { background:radial-gradient(circle at 84% 18%,rgba(255,138,114,.22),transparent 31%),radial-gradient(circle at 18% 32%,rgba(255,229,219,.92),transparent 32%),linear-gradient(180deg,#FFF9F7 0%,#FFFDFB 88%); }.home-hero::before { background-image:radial-gradient(#F2B9AE 1px,transparent 1px); }.home-hero-avatar-item { border-color:rgba(255,213,204,.92); box-shadow:0 10px 25px rgba(151,65,73,.14); }.home-hero-avatar-img { background:var(--sona-surface); }
.home-nav-cta { background:var(--sona-coral-deep); box-shadow:0 8px 20px rgba(var(--sona-coral-rgb),.24); }.home-feature-card--dark { background:#984854; border-color:#984854; }.home-feature-card--dark::after { background:rgba(255,196,181,.20); }.home-feature-card--dark .home-feature-icon { color:#FFE0D7; }.home-feature-card--dark .home-feature-num,.home-feature-card--dark p { color:#FFE3DB; }.home-download-card { background:radial-gradient(circle at 82% 18%,rgba(255,211,196,.56),transparent 30%),linear-gradient(135deg,#B84C5B 0%,#E35D64 54%,#FF7967 100%); }.home-download-copy > p { color:#FFF0EB; }.home-cta-primary--light { color:var(--sona-coral-deep); box-shadow:0 14px 29px rgba(154,62,74,.22); }.account-plan-block { background:#984854; }
.auth-page { --auth-ink:var(--sona-ink); --auth-muted:#80666B; background:#FFF8F5; }.auth-story { background:radial-gradient(circle at 78% 28%,rgba(255,211,196,.52),transparent 34%),radial-gradient(circle at 14% 82%,rgba(255,138,114,.32),transparent 35%),linear-gradient(145deg,#B84C5B 0%,#E35D64 54%,#FF7967 100%); }.auth-eyebrow { color:#FFE0D7; }.auth-story-copy h1 span { color:#FFF4F0; }.auth-story-copy p,.auth-conversation-head span,.auth-story-footer { color:#FFF0EB; }.auth-message--right { background:var(--sona-coral); }.auth-typing i { background:#FFE0D7; }.auth-panel-wrap { background:#FFFDFC; }.auth-tabs { background:#FFF0EB; }.auth-field input { border-color:var(--sona-line); background:#FFF9F7; }.auth-field input:focus { border-color:var(--sona-coral); }.auth-assurance { border-top-color:var(--sona-line); }.auth-assurance span { color:var(--sona-coral); }
.journey-settings-card { background:linear-gradient(135deg,#FFF9F6,#FFF0EB); }.journey-settings-head p { color:#80666B; }.ledger-page .ledger-tabs { background:#FFF0EB; }.ledger-page .ledger-list { border-color:var(--sona-line); box-shadow:0 9px 25px rgba(113,52,58,.08); }.ledger-page .ledger-row { border-bottom-color:#F5D8D0; }.ledger-page .ledger-row-label,.ledger-state strong { color:var(--sona-ink); }.ledger-page .ledger-row-date,.ledger-state p { color:#92777B; }
.account-language-picker { min-height:60px; padding:12px 15px; display:flex; align-items:center; justify-content:space-between; gap:16px; border:1px solid var(--sona-line,#e2e7ef); border-radius:16px; background:#fff; color:var(--sona-ink,#172033); box-shadow:0 9px 25px rgba(113,52,58,.08); }.account-language-picker > span { color:#697586; font-size:11px; font-weight:650; }.account-language-picker select { min-width:132px; appearance:auto; border:1px solid var(--sona-line,#d6dde7); border-radius:11px; background:#fff9f7; color:var(--sona-ink,#172033); padding:9px 11px; margin:0; font:inherit; font-size:12px; font-weight:750; cursor:pointer; }

/* 語音通話覆蓋層：固定在聊天室視窗上方，避免被聊天內容或父層 overflow 撐開。 */
#callOverlay.call-overlay { position:fixed !important; inset:0 !important; width:100%; height:100%; box-sizing:border-box; }
#callOverlay .call-avatar { width:120px !important; height:120px !important; flex:0 0 120px; object-fit:cover; }
#callOverlay .call-name, #callOverlay .call-status, #callOverlay .call-timer, #callOverlay .call-low-balance { flex:0 0 auto; }

/* 通話開始前的麥克風／點數確認視窗。 */
.call-preflight[hidden] { display:none !important; }
.call-preflight { position:fixed; inset:0; z-index:70; display:grid; place-items:end center; padding:18px; }
.call-preflight-backdrop { position:absolute; inset:0; width:100%; height:100%; border:0; background:rgba(10,18,31,.54); backdrop-filter:blur(7px); }
.call-preflight-dialog { position:relative; width:min(520px,100%); padding:24px; border:1px solid rgba(255,255,255,.8); border-radius:24px; background:#fff; box-shadow:0 30px 90px rgba(11,25,48,.3); }
.call-preflight-grab { display:block; width:42px; height:4px; margin:0 auto 20px; border-radius:99px; background:#d8dee8; }
.call-preflight-heading { display:flex; align-items:center; gap:12px; }.call-preflight-avatar { width:54px; height:54px; flex:0 0 54px; border-radius:50%; object-fit:cover; }.call-preflight-avatar--fallback { display:grid; place-items:center; background:#FFF0EB; color:var(--sona-coral); font-size:22px; font-weight:750; }.call-preflight-title-group { min-width:0; flex:1; }.call-preflight-title-group h2 { margin:0 0 4px; font-size:17px; }.call-preflight-title-group p { margin:0; color:#8490a1; font-size:11px; }.call-preflight-balance { color:var(--sona-coral); font-size:16px; white-space:nowrap; }
.call-preflight-guidance { display:grid; gap:8px; margin:20px 0; padding:14px; border-radius:14px; background:#FFF8F5; color:#657287; font-size:11px; line-height:1.5; }.call-preflight-guidance p { display:flex; align-items:flex-start; gap:8px; margin:0; }.call-preflight-guidance i { width:6px; height:6px; margin-top:5px; flex:0 0 6px; border-radius:50%; background:var(--sona-coral); }.call-preflight-notice { min-height:18px; margin:0 0 10px; color:#c0392b; font-size:11px; }.call-preflight-primary { width:100%; min-height:46px; display:flex; align-items:center; justify-content:center; gap:8px; border:0; border-radius:13px; background:var(--sona-coral); color:#fff; font:inherit; font-size:12px; font-weight:750; text-decoration:none; cursor:pointer; }.call-preflight-primary--plans { background:#fff0eb; color:var(--sona-coral-deep); }.call-preflight-cancel { width:100%; margin-top:10px; padding:8px; border:0; background:transparent; color:#7f8b9c; font:inherit; font-size:11px; cursor:pointer; }
