* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; user-select: none; -webkit-user-select: none; }

:root {
    --bg: #2A2A2E;
    --bg-soft: #313135;
    --card: #35353A;
    --card-hi: #3E3E44;
    --brand: #B8A8E0;
    --brand-deep: #9A88D0;
    --brand-glow: rgba(184,168,224,0.35);
    --ink: #F5F3F7;
    --ink-soft: #A8A8B0;
    --ink-faint: #707078;
    --line: rgba(255,255,255,0.08);
    --line-hi: rgba(255,255,255,0.14);
    --danger: #FF6B6B;
    --success: #6BE8A8;
    --warn: #E8A858;
}

html, body {
    height: 100%;
    overflow: hidden;
    font-family: "Inter", -apple-system, BlinkMacSystemFont, "PingFang SC", sans-serif;
    background: var(--bg);
    color: var(--ink);
    -webkit-font-smoothing: antialiased;
}

.app {
    max-width: 420px;
    margin: 0 auto;
    height: 100vh;
    height: 100dvh;
    display: flex;
    flex-direction: column;
    background: var(--bg);
    position: relative;
    overflow: hidden;
}
.app::before {
    content: '';
    position: absolute;
    top: -20%; left: 50%;
    transform: translateX(-50%);
    width: 600px; height: 600px;
    background: radial-gradient(circle, rgba(184,168,224,0.07) 0%, transparent 60%);
    pointer-events: none;
    z-index: 0;
    transition: background 0.4s;
}
.app.recording::before { background: radial-gradient(circle, rgba(255,107,107,0.12) 0%, transparent 60%); }
.app.playing::before { background: radial-gradient(circle, rgba(232,168,88,0.12) 0%, transparent 60%); }

.header {
    flex-shrink: 0;
    padding: 20px 22px 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    z-index: 2;
}
.logo {
    font-size: 17px;
    font-weight: 700;
    letter-spacing: -0.3px;
    color: var(--ink);
    cursor: pointer;
}
.logo .dot {
    display: inline-block;
    width: 5px; height: 5px;
    background: var(--brand);
    border-radius: 50%;
    margin: 0 3px;
    vertical-align: middle;
    box-shadow: 0 0 12px var(--brand-glow);
    transition: background 0.3s, box-shadow 0.3s;
}
.app.recording .logo .dot {
    background: var(--danger);
    box-shadow: 0 0 16px rgba(255,107,107,0.6);
    animation: pulse 1s infinite;
}
.header-right {
    display: flex;
    align-items: center;
    gap: 8px;
}
.lang-btn {
    height: 32px;
    min-width: 40px;
    padding: 0 10px;
    border-radius: 30px;
    background: var(--card);
    border: 1px solid var(--line);
    color: var(--ink-soft);
    cursor: pointer;
    font-family: inherit;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.5px;
    transition: 0.15s;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}
.lang-btn:active {
    transform: scale(0.9);
    background: rgba(184,168,224,0.1);
}
.share-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--card);
    border: 1px solid var(--line);
    color: var(--ink-soft);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.15s;
    flex-shrink: 0;
    padding: 0;
}
.share-btn:active {
    transform: scale(0.9);
    background: rgba(184,168,224,0.1);
}
.share-btn svg { width: 16px; height: 16px; }
.loc {
    display: flex; align-items: center; gap: 6px;
    font-size: 12px; font-weight: 500;
    color: var(--ink-soft);
    background: var(--card);
    padding: 6px 12px; border-radius: 30px;
    border: 1px solid var(--line);
    cursor: pointer;
    transition: 0.15s;
}
.loc:active { transform: scale(0.96); opacity: 0.7; }
.loc .pulse {
    width: 6px; height: 6px;
    background: var(--brand); border-radius: 50%;
    box-shadow: 0 0 8px var(--brand-glow);
    animation: pulse 2s infinite;
    flex-shrink: 0;
}
.loc .txt { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 110px; }
.loc.loading .pulse { animation: none; opacity: 0.3; }
.loc.loading .txt { color: var(--ink-faint); }
@keyframes pulse {
    0%, 100% { opacity: 0.3; transform: scale(0.8); }
    50% { opacity: 1; transform: scale(1.2); }
}

.canvas { flex: 1; position: relative; overflow: hidden; z-index: 1; }

.island {
    position: absolute;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    animation: float 5s ease-in-out infinite;
    border: 1px solid rgba(255,255,255,0.1);
    cursor: pointer;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transition: transform 0.2s;
}
.island:active { transform: translate(-50%, -50%) scale(0.92) !important; }
.island .num { font-size: 22px; font-weight: 700; letter-spacing: -1px; line-height: 1; }
.island .num.sm { font-size: 16px; }
.island .num.xs { font-size: 13px; }
.island .wave { display: flex; align-items: center; gap: 2px; margin-top: 6px; height: 10px; }
.island .wave span { display: block; width: 2px; background: currentColor; opacity: 0.7; border-radius: 2px; }
.island .wave span:nth-child(1) { height: 4px; }
.island .wave span:nth-child(2) { height: 9px; }
.island .wave span:nth-child(3) { height: 6px; }
.island .wave span:nth-child(4) { height: 10px; }
.island .wave span:nth-child(5) { height: 5px; }
.island .meta { font-size: 9px; font-weight: 500; margin-top: 5px; opacity: 0.85; display: flex; align-items: center; gap: 2px; }
.island .meta .dir { font-size: 11px; }
.island.xl { width: 116px; height: 116px; }
.island.lg { width: 92px; height: 92px; }
.island.md { width: 74px; height: 74px; }
.island.sm { width: 60px; height: 60px; }
.island.c1 { background: radial-gradient(circle at 30% 25%, rgba(232,168,208,0.5), rgba(232,168,208,0.22)); color: #F0B8E0; box-shadow: 0 8px 32px rgba(232,168,208,0.2), inset 0 1px 0 rgba(255,255,255,0.12); }
.island.c2 { background: radial-gradient(circle at 30% 25%, rgba(140,180,240,0.5), rgba(140,180,240,0.22)); color: #A8C8F0; box-shadow: 0 8px 32px rgba(140,180,240,0.2), inset 0 1px 0 rgba(255,255,255,0.12); }
.island.c3 { background: radial-gradient(circle at 30% 25%, rgba(184,168,224,0.55), rgba(184,168,224,0.25)); color: #C8B8F0; box-shadow: 0 8px 40px rgba(184,168,224,0.25), inset 0 1px 0 rgba(255,255,255,0.12); }
.island.c4 { background: radial-gradient(circle at 30% 25%, rgba(140,220,180,0.5), rgba(140,220,180,0.22)); color: #A8E0C0; box-shadow: 0 8px 32px rgba(140,220,180,0.2), inset 0 1px 0 rgba(255,255,255,0.12); }
.island.c5 { background: radial-gradient(circle at 30% 25%, rgba(240,200,140,0.5), rgba(240,200,140,0.22)); color: #F0D0A0; box-shadow: 0 8px 32px rgba(240,200,140,0.2), inset 0 1px 0 rgba(255,255,255,0.12); }

@keyframes float {
    0%, 100% { transform: translate(-50%, -50%) translateY(0); }
    50% { transform: translate(-50%, -50%) translateY(-6px); }
}

/* 指南针刻度环 */
.compass-ring {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    border: 1px dashed rgba(184,168,224,0.1);
    pointer-events: none;
    z-index: 0;
}
.compass-ring .ring-label {
    position: absolute;
    top: 50%;
    right: -8px;
    transform: translate(100%, -50%);
    font-size: 9px;
    color: rgba(184,168,224,0.35);
    font-weight: 500;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.dir-label {
    position: absolute;
    font-size: 11px;
    font-weight: 700;
    color: rgba(184,168,224,0.35);
    letter-spacing: 1px;
    pointer-events: none;
    user-select: none;
    z-index: 0;
}
.dir-label.dir-n { top: 8px; left: 50%; transform: translateX(-50%); }
.dir-label.dir-s { bottom: 8px; left: 50%; transform: translateX(-50%); }
.dir-label.dir-e { right: 8px; top: 50%; transform: translateY(-50%); }
.dir-label.dir-w { left: 8px; top: 50%; transform: translateY(-50%); }

.me-dot {
    position: absolute;
    top: 50%; left: 50%;
    width: 14px; height: 14px;
    border-radius: 50%;
    background: linear-gradient(135deg, #C8B8F0, #9A88D0);
    transform: translate(-50%, -50%);
    box-shadow: 0 0 0 6px rgba(184,168,224,0.15), 0 0 24px rgba(184,168,224,0.5);
    z-index: 5;
    pointer-events: none;
    animation: mePulse 2.5s ease-in-out infinite;
}
.me-dot::after {
    content: '';
    position: absolute;
    inset: 4px;
    border-radius: 50%;
    background: rgba(255,255,255,0.7);
}
@keyframes mePulse {
    0%, 100% { box-shadow: 0 0 0 6px rgba(184,168,224,0.15), 0 0 24px rgba(184,168,224,0.5); }
    50% { box-shadow: 0 0 0 12px rgba(184,168,224,0.05), 0 0 36px rgba(184,168,224,0.7); }
}

/* 欢迎气泡 */
.welcome-island {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 130px;
    height: 130px;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transform: translate(-50%, -50%);
    background: radial-gradient(circle at 30% 25%, rgba(255,228,168,0.85), rgba(232,200,120,0.55));
    color: #4A3A1A;
    box-shadow:
            0 12px 48px rgba(232,200,120,0.5),
            0 0 80px rgba(255,228,168,0.35),
            inset 0 2px 0 rgba(255,255,255,0.5);
    border: 1px solid rgba(255,255,255,0.4);
    animation: welcomeFloat 4s ease-in-out infinite, welcomePulse 3s ease-in-out infinite;
    z-index: 25;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}
.welcome-island:active {
    transform: translate(-50%, -50%) scale(0.92);
}
.welcome-island .icon {
    font-size: 38px;
    line-height: 1;
    margin-bottom: 4px;
    animation: sparkle 2s ease-in-out infinite;
}
.welcome-island .label {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.3px;
    margin-top: 4px;
    text-align: center;
    padding: 0 8px;
    line-height: 1.3;
}
.welcome-island .wave {
    display: flex;
    align-items: center;
    gap: 2px;
    margin-top: 6px;
    height: 10px;
}
.welcome-island .wave span {
    display: block;
    width: 2px;
    background: #4A3A1A;
    opacity: 0.5;
    border-radius: 2px;
}
.welcome-island .wave span:nth-child(1) { height: 4px; }
.welcome-island .wave span:nth-child(2) { height: 9px; }
.welcome-island .wave span:nth-child(3) { height: 6px; }
.welcome-island .wave span:nth-child(4) { height: 10px; }
.welcome-island .wave span:nth-child(5) { height: 5px; }

.welcome-island.playing .icon { animation: none; }
.welcome-island.playing .wave span {
    animation: wave-dance 0.6s ease-in-out infinite alternate;
}

@keyframes welcomeFloat {
    0%, 100% { transform: translate(-50%, -50%) translateY(0); }
    50% { transform: translate(-50%, -50%) translateY(-8px); }
}
@keyframes welcomePulse {
    0%, 100% {
        box-shadow:
                0 12px 48px rgba(232,200,120,0.5),
                0 0 80px rgba(255,228,168,0.35),
                inset 0 2px 0 rgba(255,255,255,0.5);
    }
    50% {
        box-shadow:
                0 12px 48px rgba(232,200,120,0.7),
                0 0 120px rgba(255,228,168,0.55),
                inset 0 2px 0 rgba(255,255,255,0.5);
    }
}
@keyframes sparkle {
    0%, 100% { transform: scale(1) rotate(0deg); }
    50% { transform: scale(1.15) rotate(8deg); }
}
@keyframes wave-dance {
    0% { transform: scaleY(0.5); }
    100% { transform: scaleY(1.2); }
}

/* 定位错误页 */
.loc-error {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    width: 80%;
    max-width: 320px;
    color: var(--ink-soft);
}
.loc-error .emoji { font-size: 56px; margin-bottom: 16px; opacity: 0.6; }
.loc-error .title { font-size: 17px; font-weight: 700; color: var(--ink); margin-bottom: 10px; }
.loc-error .desc { font-size: 13px; line-height: 1.7; color: var(--ink-soft); margin-bottom: 22px; }
.loc-error .btn {
    background: linear-gradient(135deg, #C8B8F0 0%, #9A88D0 100%);
    color: #1A1822;
    border: none;
    padding: 12px 28px;
    border-radius: 40px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    box-shadow: 0 4px 20px rgba(184,168,224,0.35);
    transition: 0.15s;
}
.loc-error .btn:active { transform: scale(0.96); }

.bottom {
    flex-shrink: 0;
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 8px 22px 22px;
    background: var(--bg);
    position: relative;
    z-index: 200;
}
.nav-btn {
    background: none;
    border: none;
    color: var(--ink-faint);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    cursor: pointer;
    padding: 8px 16px;
    transition: 0.2s;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    font-family: inherit;
}
.nav-btn svg { width: 22px; height: 22px; }
.nav-btn.active { color: var(--brand); }

.rec-btn {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, #C8B8F0 0%, #9A88D0 100%);
    border: none;
    color: #1A1822;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 28px rgba(184,168,224,0.45), 0 0 60px rgba(184,168,224,0.25);
    margin-top: -22px;
    transition: all 0.2s cubic-bezier(0.18, 0.89, 0.32, 1.28);
    position: relative;
    z-index: 11;
}
.rec-btn:active { transform: scale(0.92); }
.rec-btn svg { width: 26px; height: 26px; }

.sheet-mask {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
    z-index: 399;
}
.sheet-mask.show { opacity: 1; pointer-events: auto; }

.sheet {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%) translateY(100%);
    width: 100%;
    max-width: 420px;
    background: var(--card);
    border-radius: 28px 28px 0 0;
    padding: 28px 24px 40px;
    transition: transform 0.4s cubic-bezier(0.18, 0.89, 0.32, 1.28);
    z-index: 400;
    box-shadow: 0 -8px 60px rgba(0,0,0,0.5);
    border-top: 1px solid var(--line);
}
.sheet.show { transform: translateX(-50%) translateY(0); }

.grabber {
    width: 36px; height: 4px;
    background: var(--line-hi);
    border-radius: 4px;
    margin: 0 auto 24px;
}

.wave-viz {
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    margin-bottom: 20px;
}
.wave-viz .bar {
    width: 3px;
    background: var(--brand);
    border-radius: 3px;
    height: 4px;
    transition: height 0.08s ease, background 0.3s;
    opacity: 0.5;
}
.app.recording .wave-viz .bar { background: var(--danger); opacity: 1; }
.app.playing .wave-viz .bar { background: var(--warn); opacity: 1; }
.app.has-recording .wave-viz .bar { background: var(--success); opacity: 0.9; }

.rec-circle {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    background: linear-gradient(135deg, #C8B8F0 0%, #9A88D0 100%);
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #1A1822;
    box-shadow: 0 12px 40px rgba(184,168,224,0.4), 0 0 80px rgba(184,168,224,0.2);
    position: relative;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.18, 0.89, 0.32, 1.28);
    touch-action: none;
}
.rec-circle svg { width: 42px; height: 42px; }
.rec-circle.recording {
    background: linear-gradient(135deg, #FF6B6B 0%, #D04848 100%);
    color: #fff;
    transform: scale(1.05);
    animation: rec-pulse 1s infinite;
}
@keyframes rec-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(255,107,107,0.5), 0 12px 40px rgba(255,107,107,0.3); }
    50% { box-shadow: 0 0 0 24px rgba(255,107,107,0), 0 12px 40px rgba(255,107,107,0.3); }
}
.rec-circle.will-cancel {
    background: linear-gradient(135deg, #A8A8B0 0%, #707078 100%);
    transform: scale(0.85);
    animation: none;
}
.rec-circle.has-recording {
    background: linear-gradient(135deg, #6BE8A8 0%, #4AC088 100%);
    color: #1A1822;
    box-shadow: 0 12px 40px rgba(107,232,168,0.35), 0 0 80px rgba(107,232,168,0.2);
}
.rec-circle.playing {
    background: linear-gradient(135deg, #E8A858 0%, #C08838 100%);
    color: #1A1822;
    animation: play-pulse 1.2s infinite;
}
@keyframes play-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(232,168,88,0.4), 0 12px 40px rgba(232,168,88,0.3); }
    50% { box-shadow: 0 0 0 16px rgba(232,168,88,0), 0 12px 40px rgba(232,168,88,0.3); }
}

.rec-timer {
    text-align: center;
    font-size: 36px;
    font-weight: 300;
    letter-spacing: 2px;
    color: var(--ink);
    font-variant-numeric: tabular-nums;
    transition: color 0.3s;
    line-height: 1;
}
.rec-timer.recording { color: var(--danger); }
.rec-timer.has-recording { color: var(--success); }
.rec-timer.playing { color: var(--warn); }

.rec-hint {
    text-align: center;
    font-size: 11px;
    color: var(--ink-faint);
    margin-top: 10px;
    letter-spacing: 1.2px;
    font-weight: 600;
    text-transform: uppercase;
    min-height: 16px;
    transition: color 0.3s;
}
.rec-hint.recording { color: var(--danger); }
.rec-hint.has-recording { color: var(--success); }
.rec-hint.playing { color: var(--warn); }

.upload-progress {
    height: 3px;
    background: var(--line);
    border-radius: 3px;
    margin-top: 16px;
    overflow: hidden;
    opacity: 0;
    transition: opacity 0.3s;
}
.upload-progress.show { opacity: 1; }
.upload-progress .fill {
    height: 100%;
    width: 0%;
    background: var(--brand);
    border-radius: 3px;
    transition: width 0.3s;
}

.actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
    opacity: 0;
    transform: translateY(10px);
    pointer-events: none;
    transition: all 0.3s;
}
.actions.show { opacity: 1; transform: translateY(0); pointer-events: auto; }
.action-btn {
    flex: 1;
    padding: 14px;
    border-radius: 40px;
    border: none;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: all 0.15s;
    font-family: inherit;
}
.action-btn:active { transform: scale(0.96); }
.action-btn.cancel { background: rgba(255,255,255,0.08); color: var(--ink-soft); }
.action-btn.play { background: rgba(232,168,88,0.18); color: var(--warn); }
.action-btn.send {
    background: linear-gradient(135deg, #C8B8F0 0%, #9A88D0 100%);
    color: #1A1822;
    box-shadow: 0 4px 20px rgba(184,168,224,0.35);
}

.sheet-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255,255,255,0.08);
    border: none;
    color: var(--ink-faint);
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}
.sheet-close:active { background: rgba(255,255,255,0.14); }

.profile {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 210;
    padding: 20px;
}
.profile.show { display: flex; }
.profile-card {
    background: var(--card);
    border-radius: 28px;
    padding: 24px 20px 20px;
    width: 100%;
    max-width: 340px;
    max-height: 78vh;
    overflow-y: auto;
    animation: pop 0.35s cubic-bezier(0.18, 0.89, 0.32, 1.28);
    box-shadow: 0 24px 64px rgba(0,0,0,0.6);
    border: 1px solid var(--line);
    position: relative;
}
@keyframes pop {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}
.profile-card::-webkit-scrollbar { display: none; }

.profile-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.profile-head .count { font-size: 13px; color: var(--ink-soft); font-weight: 500; }
.profile-head .count b { color: var(--ink); font-weight: 700; font-size: 16px; }
.profile-head .x { background: none; border: none; font-size: 20px; color: var(--ink-faint); cursor: pointer; padding: 4px 8px; }

.voice-list { display: flex; flex-direction: column; gap: 10px; }
.voice { background: var(--bg-soft); border-radius: 18px; padding: 14px 16px; border: 1px solid var(--line); transition: 0.15s; }
.voice .top { display: flex; align-items: center; gap: 12px; }
.play {
    width: 40px; height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #C8B8F0 0%, #9A88D0 100%);
    color: #1A1822;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(184,168,224,0.3);
}
.play svg { width: 16px; height: 16px; margin-left: 2px; }

.v-info { flex: 1; min-width: 0; }
.v-wave { display: flex; align-items: center; gap: 2px; height: 20px; }
.v-wave span { display: block; width: 2.5px; background: var(--brand); opacity: 0.4; border-radius: 2px; transition: opacity 0.15s; }
.v-wave.playing span { opacity: 1; animation: wave-dance 0.6s ease-in-out infinite alternate; }
.v-wave span:nth-child(1) { height: 6px; animation-delay: 0.0s; }
.v-wave span:nth-child(2) { height: 12px; animation-delay: 0.08s; }
.v-wave span:nth-child(3) { height: 8px; animation-delay: 0.16s; }
.v-wave span:nth-child(4) { height: 16px; animation-delay: 0.04s; }
.v-wave span:nth-child(5) { height: 10px; animation-delay: 0.12s; }
.v-wave span:nth-child(6) { height: 18px; animation-delay: 0.20s; }
.v-wave span:nth-child(7) { height: 6px; animation-delay: 0.06s; }
.v-wave span:nth-child(8) { height: 14px; animation-delay: 0.14s; }
.v-wave span:nth-child(9) { height: 8px; animation-delay: 0.22s; }
.v-wave span:nth-child(10) { height: 12px; animation-delay: 0.02s; }
.v-wave span:nth-child(11) { height: 6px; animation-delay: 0.10s; }
.v-wave span:nth-child(12) { height: 10px; animation-delay: 0.18s; }

.v-meta { display: flex; justify-content: space-between; font-size: 10px; color: var(--ink-faint); margin-top: 4px; font-weight: 500; }

.v-hear {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: var(--brand);
    font-weight: 600;
    flex-shrink: 0;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 30px;
    transition: 0.15s;
    font-family: inherit;
}
.v-hear:active { transform: scale(0.92); }
.v-hear svg { width: 14px; height: 14px; }
.v-hear.heard { color: var(--ink-faint); }

.profile-foot {
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px solid var(--line);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: var(--ink-faint);
}
.profile-foot .visit { display: flex; align-items: center; gap: 5px; }

.me-page {
    position: absolute;
    inset: 0;
    background: var(--bg);
    z-index: 50;
    display: none;
    flex-direction: column;
    padding: 20px 22px 100px;
    overflow-y: auto;
}
.me-page.show { display: flex; }
.me-page::-webkit-scrollbar { display: none; }

.me-title { font-size: 28px; font-weight: 800; letter-spacing: -1px; margin-bottom: 20px; }
.me-card { background: var(--card); border-radius: 22px; padding: 8px 20px; margin-bottom: 14px; border: 1px solid var(--line); }
.me-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 0;
    border-bottom: 1px solid var(--line);
    cursor: pointer;
    background: none;
    border-left: none;
    border-right: none;
    border-top: none;
    width: 100%;
    text-align: left;
    font-family: inherit;
}
.me-row:last-child { border-bottom: none; }
.me-row .label { font-size: 14px; color: var(--ink); font-weight: 500; }
.me-row .value {
    font-size: 13px;
    color: var(--ink-soft);
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 60%;
    text-align: right;
}
.me-row .value.bound { color: #88D0A8; }
.me-row .value.brand { color: var(--brand); }

.me-stat-row { display: flex; gap: 12px; margin-bottom: 14px; }
.me-stat {
    flex: 1;
    background: var(--card);
    border-radius: 20px;
    padding: 20px 18px;
    border: 1px solid var(--line);
    position: relative;
    overflow: hidden;
}
.me-stat::before {
    content: '';
    position: absolute;
    top: -30%; right: -30%;
    width: 100px; height: 100px;
    background: radial-gradient(circle, rgba(184,168,224,0.15) 0%, transparent 70%);
    pointer-events: none;
}
.me-stat .n { font-size: 28px; font-weight: 800; letter-spacing: -1px; color: var(--brand); line-height: 1; position: relative; }
.me-stat .l { font-size: 10px; font-weight: 600; color: var(--ink-faint); text-transform: uppercase; letter-spacing: 0.8px; margin-top: 6px; position: relative; }

.me-voice-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 14px; }
.me-voice {
    background: var(--card);
    border-radius: 16px;
    padding: 12px 16px;
    border: 1px solid var(--line);
    display: flex;
    align-items: center;
    gap: 12px;
}
.me-voice .icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(184,168,224,0.15);
    color: var(--brand);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    flex-shrink: 0;
    border: none;
    cursor: pointer;
    transition: all 0.15s;
    padding: 0;
    font-family: inherit;
}
.me-voice .icon:active:not(:disabled) { transform: scale(0.9); }
.me-voice .icon:disabled { cursor: default; opacity: 0.5; }
.me-voice .icon.playing {
    background: linear-gradient(135deg, #C8B8F0 0%, #9A88D0 100%);
    color: #1A1822;
    box-shadow: 0 4px 16px rgba(184,168,224,0.4);
    animation: me-voice-pulse 1.2s infinite;
}
.me-voice .icon.playing .play-icon { margin-left: 0 !important; }
@keyframes me-voice-pulse {
    0%, 100% { box-shadow: 0 4px 16px rgba(184,168,224,0.4), 0 0 0 0 rgba(184,168,224,0.4); }
    50% { box-shadow: 0 4px 16px rgba(184,168,224,0.4), 0 0 0 8px rgba(184,168,224,0); }
}
.me-voice .info { flex: 1; min-width: 0; }
.me-voice .info .meta { font-size: 11px; color: var(--ink-faint); font-weight: 500; }
.me-voice .info .meta b { color: var(--brand); font-weight: 600; }
.me-voice .del {
    background: none;
    border: none;
    color: var(--ink-faint);
    font-size: 14px;
    cursor: pointer;
    padding: 6px;
    border-radius: 50%;
    transition: 0.15s;
    font-family: inherit;
}
.me-voice .del:active { color: var(--danger); background: rgba(255,107,107,0.1); }

.me-empty { text-align: center; padding: 40px 0; color: var(--ink-faint); font-size: 13px; }
.me-logout {
    background: none;
    border: none;
    color: var(--ink-faint);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    padding: 16px;
    width: 100%;
    text-align: center;
    letter-spacing: 0.3px;
    font-family: inherit;
}
.me-logout:active { color: var(--danger); }

.bind-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 300;
    padding: 20px;
}
.bind-modal.show { display: flex; }
.bind-card {
    background: var(--card);
    border-radius: 28px;
    padding: 28px 24px 24px;
    width: 100%;
    max-width: 340px;
    animation: pop 0.35s cubic-bezier(0.18, 0.89, 0.32, 1.28);
    box-shadow: 0 24px 64px rgba(0,0,0,0.6);
    border: 1px solid var(--line);
    position: relative;
}
.bind-card h3 { font-size: 18px; font-weight: 700; margin-bottom: 6px; }
.bind-card .sub { font-size: 12px; color: var(--ink-faint); margin-bottom: 20px; line-height: 1.5; }
.bind-card label {
    display: block;
    font-size: 11px;
    color: var(--ink-faint);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}
.bind-card input,
.bind-card textarea {
    width: 100%;
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 12px 16px;
    font-size: 14px;
    color: var(--ink);
    outline: none;
    font-family: inherit;
    margin-bottom: 14px;
    transition: 0.15s;
}
.bind-card input:focus,
.bind-card textarea:focus { border-color: var(--brand); }
.bind-card input::placeholder,
.bind-card textarea::placeholder { color: var(--ink-faint); }
.bind-card textarea { resize: none; height: 80px; }

.bind-code-row { display: flex; gap: 8px; }
.bind-code-row input { flex: 1; margin-bottom: 0; }
.bind-code-row button {
    background: var(--brand);
    color: #1A1822;
    border: none;
    padding: 0 16px;
    border-radius: 14px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    white-space: nowrap;
    transition: 0.15s;
}
.bind-code-row button:disabled { background: var(--line); color: var(--ink-faint); cursor: default; }
.bind-code-row button:active:not(:disabled) { transform: scale(0.95); }

.bind-submit {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #C8B8F0 0%, #9A88D0 100%);
    border: none;
    border-radius: 40px;
    color: #1A1822;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    margin-top: 8px;
    box-shadow: 0 4px 20px rgba(184,168,224,0.35);
    font-family: inherit;
    transition: 0.15s;
}
.bind-submit:active { transform: scale(0.97); }
.bind-submit.ghost { background: rgba(255,255,255,0.08); color: var(--ink-soft); box-shadow: none; }

.bound-view { display: none; }
.bound-view.show { display: block; }
.bound-email-box {
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 18px 16px;
    margin-bottom: 20px;
    text-align: center;
}
.bound-email-box .avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, #C8B8F0 0%, #9A88D0 100%);
    color: #1A1822;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin: 0 auto 12px;
    box-shadow: 0 8px 24px rgba(184,168,224,0.3);
}
.bound-email-box .email { font-size: 14px; color: var(--ink); font-weight: 600; word-break: break-all; }
.bound-email-box .label {
    font-size: 11px;
    color: var(--ink-faint);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
    font-weight: 600;
}
.bind-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255,255,255,0.06);
    border: none;
    color: var(--ink-faint);
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}
.bind-close:active { background: rgba(255,255,255,0.12); }

.captcha-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.75);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 400;
    padding: 20px;
}
.captcha-modal.show { display: flex; }
.captcha-card {
    background: var(--card);
    border-radius: 24px;
    padding: 28px 24px 24px;
    width: 100%;
    max-width: 320px;
    animation: pop 0.3s cubic-bezier(0.18, 0.89, 0.32, 1.28);
    box-shadow: 0 24px 64px rgba(0,0,0,0.7);
    border: 1px solid var(--line);
    position: relative;
    text-align: center;
}
.captcha-card h3 { font-size: 16px; font-weight: 700; margin-bottom: 4px; }
.captcha-card .sub { font-size: 11px; color: var(--ink-faint); margin-bottom: 20px; }
.captcha-question {
    font-size: 32px;
    font-weight: 700;
    color: var(--brand);
    letter-spacing: 1px;
    margin-bottom: 20px;
    font-variant-numeric: tabular-nums;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.captcha-card input {
    width: 100%;
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 14px 16px;
    font-size: 18px;
    color: var(--ink);
    outline: none;
    font-family: inherit;
    margin-bottom: 14px;
    text-align: center;
    font-weight: 600;
    transition: 0.15s;
    -moz-appearance: textfield;
}
.captcha-card input::-webkit-outer-spin-button,
.captcha-card input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.captcha-card input:focus { border-color: var(--brand); }
.captcha-card input::placeholder { color: var(--ink-faint); font-weight: 400; }
.captcha-card input.shake { animation: shake 0.3s; border-color: var(--danger); }
@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-8px); }
    75% { transform: translateX(8px); }
}
.captcha-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(255,255,255,0.06);
    border: none;
    color: var(--ink-faint);
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}
.captcha-close:active { background: rgba(255,255,255,0.12); }
.captcha-error {
    font-size: 11px;
    color: var(--danger);
    margin-top: 10px;
    min-height: 14px;
    font-weight: 500;
}

.toast {
    position: fixed;
    bottom: 120px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: rgba(53,53,58,0.95);
    backdrop-filter: blur(12px);
    color: var(--ink);
    padding: 12px 24px;
    border-radius: 40px;
    font-size: 13px;
    font-weight: 500;
    box-shadow: 0 8px 32px rgba(0,0,0,0.5);
    border: 1px solid var(--line);
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s;
    z-index: 2000;
    white-space: nowrap;
    max-width: 90%;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

.loading {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    color: var(--ink-faint);
    font-size: 12px;
}
.loading .spinner {
    width: 24px;
    height: 24px;
    border: 2px solid rgba(184,168,224,0.15);
    border-top: 2px solid var(--brand);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.bind-required-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 500;
    padding: 20px;
}
.bind-required-modal.show { display: flex; }
.bind-required-card {
    background: var(--card);
    border-radius: 24px;
    padding: 28px 24px 22px;
    width: 100%;
    max-width: 320px;
    text-align: center;
    animation: pop 0.3s cubic-bezier(0.18, 0.89, 0.32, 1.28);
    box-shadow: 0 24px 64px rgba(0,0,0,0.7);
    border: 1px solid var(--line);
}
.bind-required-card .emoji { font-size: 44px; margin-bottom: 14px; }
.bind-required-card .title { font-size: 17px; font-weight: 700; margin-bottom: 8px; }
.bind-required-card .desc { font-size: 13px; color: var(--ink-soft); line-height: 1.6; margin-bottom: 22px; }
.bind-required-card .btn-row { display: flex; gap: 10px; }
.bind-required-card .btn-row button {
    flex: 1;
    padding: 12px;
    border-radius: 40px;
    border: none;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: 0.15s;
}
.bind-required-card .btn-row button:active { transform: scale(0.96); }
.bind-required-card .btn-cancel { background: rgba(255,255,255,0.08); color: var(--ink-soft); }
.bind-required-card .btn-go {
    background: linear-gradient(135deg, #C8B8F0 0%, #9A88D0 100%);
    color: #1A1822;
    box-shadow: 0 4px 16px rgba(184,168,224,0.35);
}

.loading-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.65);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 5000;
    opacity: 0;
    transition: opacity 0.2s;
    pointer-events: auto;
}
.loading-overlay.show { display: flex; opacity: 1; }
.loading-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
    padding: 28px 32px;
    background: var(--card);
    border-radius: 20px;
    border: 1px solid var(--line);
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
    min-width: 180px;
    animation: loadingPop 0.25s cubic-bezier(0.18, 0.89, 0.32, 1.28);
}
@keyframes loadingPop {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}
.loading-spinner {
    width: 36px;
    height: 36px;
    border: 3px solid rgba(184,168,224,0.15);
    border-top: 3px solid var(--brand);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}
.loading-text {
    font-size: 13px;
    color: var(--ink-soft);
    font-weight: 500;
    letter-spacing: 0.3px;
    text-align: center;
    max-width: 220px;
    line-height: 1.5;
}

.pwa-banner {
    position: fixed;
    left: 50%;
    bottom: 90px;
    transform: translateX(-50%) translateY(20px);
    width: calc(100% - 32px);
    max-width: 400px;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 20px;
    padding: 14px 16px;
    display: none;
    align-items: center;
    gap: 12px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
    z-index: 2500;
    opacity: 0;
    transition: all 0.3s;
}
.pwa-banner.show {
    display: flex;
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}
.pwa-banner-icon { font-size: 28px; flex-shrink: 0; }
.pwa-banner-text { flex: 1; min-width: 0; }
.pwa-banner-title { font-size: 13px; font-weight: 700; color: var(--ink); margin-bottom: 2px; }
.pwa-banner-desc { font-size: 11px; color: var(--ink-faint); line-height: 1.5; }
.pwa-banner-actions { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.pwa-btn-install {
    background: linear-gradient(135deg, #C8B8F0 0%, #9A88D0 100%);
    color: #1A1822;
    border: none;
    padding: 8px 14px;
    border-radius: 30px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    transition: 0.15s;
    white-space: nowrap;
}
.pwa-btn-install:active { transform: scale(0.95); }
.pwa-btn-install.hidden { display: none; }
.pwa-btn-close {
    background: none;
    border: none;
    color: var(--ink-faint);
    font-size: 16px;
    cursor: pointer;
    padding: 4px 6px;
    line-height: 1;
}
.pwa-btn-close:active { color: var(--danger); }

.about-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 6000;
    padding: 24px;
    opacity: 0;
    transition: opacity 0.3s;
}
.about-modal.show { display: flex; opacity: 1; }
.about-card {
    background: var(--card);
    border-radius: 28px;
    padding: 36px 28px 24px;
    width: 100%;
    max-width: 340px;
    text-align: center;
    position: relative;
    box-shadow: 0 24px 64px rgba(0,0,0,0.6);
    border: 1px solid var(--line);
    animation: aboutIn 0.4s cubic-bezier(0.18, 0.89, 0.32, 1.28);
    max-height: 85vh;
    overflow-y: auto;
}
.about-card::-webkit-scrollbar { display: none; }
@keyframes aboutIn {
    from { opacity: 0; transform: scale(0.9) translateY(20px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}
.about-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255,255,255,0.06);
    border: none;
    color: var(--ink-faint);
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.15s;
}
.about-close:active { background: rgba(255,255,255,0.12); transform: scale(0.9); }
.about-icon {
    width: 96px;
    height: 96px;
    border-radius: 24px;
    margin: 0 auto 20px;
    display: block;
    box-shadow: 0 12px 32px rgba(184,168,224,0.25);
    overflow: hidden;
}
.about-icon img { width: 100%; height: 100%; display: block; object-fit: cover; }
.about-title {
    font-size: 22px;
    font-weight: 800;
    letter-spacing: -0.5px;
    color: var(--ink);
    margin-bottom: 6px;
}
.about-title .dot {
    display: inline-block;
    width: 5px; height: 5px;
    background: var(--brand);
    border-radius: 50%;
    margin: 0 3px;
    vertical-align: middle;
    box-shadow: 0 0 12px var(--brand-glow);
}
.about-slogan {
    font-size: 11px;
    color: var(--brand);
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    margin-bottom: 20px;
}
.about-desc {
    font-size: 13px;
    color: var(--ink-soft);
    line-height: 1.7;
    margin-bottom: 8px;
    padding: 0 4px;
}
.about-desc-en {
    font-size: 12px;
    color: var(--ink-faint);
    line-height: 1.7;
    margin-bottom: 24px;
    font-style: italic;
    padding: 0 4px;
}
.about-features {
    text-align: left;
    background: rgba(255,255,255,0.03);
    border-radius: 16px;
    padding: 14px 16px;
    margin-bottom: 22px;
    border: 1px solid var(--line);
}
.about-feature {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 6px 0;
    font-size: 12px;
    color: var(--ink-soft);
    line-height: 1.5;
}
.about-feature .emoji { font-size: 16px; flex-shrink: 0; line-height: 1.2; }
.about-feature b { color: var(--ink); font-weight: 600; }
.about-actions { display: flex; gap: 10px; }
.about-btn {
    flex: 1;
    padding: 13px;
    border-radius: 40px;
    border: none;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    transition: 0.15s;
    letter-spacing: 0.3px;
}
.about-btn:active { transform: scale(0.96); }
.about-btn.share { background: rgba(255,255,255,0.08); color: var(--ink-soft); }
.about-btn.close {
    background: linear-gradient(135deg, #C8B8F0 0%, #9A88D0 100%);
    color: #1A1822;
    box-shadow: 0 4px 20px rgba(184,168,224,0.35);
}