/* ============================================================
   location.css 路 鍦扮偣椤甸潰
   ------------------------------------------------------------
   鍦扮偣椤?/ 绔嬬粯 / 鐗╁搧鏍?/ 鏂囧瓧鍖?/ 璁板綍椤?/ 閿佸畾 UI
   ============================================================ */

.location-page {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    background: #0f0a14;
    background-image:
        radial-gradient(circle at 15% 0%, rgba(169, 71, 109, 0.15), transparent 45%),
        radial-gradient(circle at 90% 100%, rgba(201, 166, 107, 0.10), transparent 50%);
    font-family: 'Segoe UI', 'Noto Sans', system-ui, sans-serif;
    color: var(--text);
    z-index: 1;
}

.location-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    flex-shrink: 0;
}

.location-title {
    font-size: 20px;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.location-actions {
    display: flex;
    gap: 10px;
}

.location-icon-btn {
    width: 42px;
    height: 42px;
    background: rgba(30, 20, 45, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(212, 106, 147, 0.22);
    border-radius: 50%;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    color: var(--text);
    padding: 0;
    margin: 0;
}

.location-icon-btn:hover {
    background: rgba(212, 106, 147, 0.18);
    border-color: rgba(212, 106, 147, 0.5);
    box-shadow: 0 0 14px rgba(212, 106, 147, 0.4);
}

.location-stage {
    flex: 1;
    position: relative;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transition: background-color .25s ease;
    background: #0f0a14;
    touch-action: none;
    /* 闃绘娴忚鍣ㄩ粯璁ゆ墜鍔?*/
    cursor: grab;
    -webkit-user-select: none;
    user-select: none;
}

.location-world {
    position: absolute;
    top: 0;
    left: 0;
    /* width / height 鐢?JS 鎸夊浘鐗囧師濮嬪儚绱犺缃?*/
    transform-origin: 0 0;
    will-change: transform;
    touch-action: none;
    -webkit-user-select: none;
    user-select: none;
    -webkit-user-drag: none;
}

.location-capsules {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    padding: 12px 20px 0;
    z-index: 2;
    pointer-events: none;
}

.location-capsules>* {
    pointer-events: auto;
}

/* ---- 鎴块棿鏍囩锛堟浛浠ｅ師鏉ョ殑瀛愮骇鍦扮偣鑳跺泭锛?--- */
.loc-room-tabs { gap: 6px; }

.loc-room-tab {
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    color: rgba(245, 235, 225, .55);
    background: rgba(255, 255, 255, .05);
    border: 1px solid rgba(255, 255, 255, .08);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: background .18s, color .18s, border-color .18s;
}

.loc-room-tab.on {
    color: #FFF;
    background: rgba(212, 106, 147, .22);
    border-color: rgba(212, 106, 147, .5);
}

html[data-mode="day"] .loc-room-tab {
    color: rgba(90, 60, 50, .6);
    background: rgba(255, 255, 255, .5);
    border-color: rgba(120, 90, 70, .14);
}

html[data-mode="day"] .loc-room-tab.on {
    color: #7A3E58;
    background: rgba(212, 106, 147, .18);
    border-color: rgba(212, 106, 147, .45);
}

/* ---- 宸︿笂瑙掑睍寮€鐨勬埛鍨嬪浘 ---- */
.loc-plan-panel { padding: 10px 20px 0; flex-shrink: 0; }

.loc-plan-head {
    font-size: 11px; letter-spacing: 2px;
    color: rgba(241, 226, 210, .45); margin-bottom: 6px;
}

.loc-plan-rooms { display: flex; flex-wrap: wrap; gap: 8px; }

.loc-plan-room {
    min-width: 62px; padding: 10px 14px; border-radius: 12px;
    font-size: 12px; color: #EFE0D0;
    background: rgba(255, 255, 255, .05);
    border: 1px solid rgba(255, 255, 255, .12);
    -webkit-tap-highlight-color: transparent;
}

.loc-plan-room.on {
    color: #FFF;
    background: rgba(212, 106, 147, .2);
    border-color: rgba(212, 106, 147, .55);
}

.loc-plan-doors {
    display: flex; flex-wrap: wrap; gap: 6px 12px;
    margin-top: 8px; font-size: 11px; color: rgba(241, 226, 210, .5);
}

html[data-mode="day"] .loc-plan-head,
html[data-mode="day"] .loc-plan-doors { color: rgba(90, 60, 50, .55); }

html[data-mode="day"] .loc-plan-room {
    color: #5B4A40; background: rgba(255, 255, 255, .55);
    border-color: rgba(120, 90, 70, .16);
}

html[data-mode="day"] .loc-plan-room.on {
    color: #7A3E58; background: rgba(212, 106, 147, .18);
    border-color: rgba(212, 106, 147, .45);
}

/* 3D 閲岀偣闂ㄥ啋鍑烘潵鐨勫皬姘旀场 */
.room3d-doorhint {
    position: absolute; z-index: 24;
    transform: translate(-50%, -50%);
    padding: 5px 11px; border-radius: 12px;
    font-size: 12px; white-space: nowrap; color: #fff;
    background: rgba(212, 106, 147, .92);
    box-shadow: 0 6px 16px rgba(0, 0, 0, .38);
    cursor: pointer;
}

.location-capsule:hover {
    background: rgba(212, 106, 147, 0.22);
    border-color: rgba(212, 106, 147, 0.6);
    box-shadow: 0 0 14px rgba(212, 106, 147, 0.35);
    transform: translateY(-1px);
}

.location-standees {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1;
}

/* 2D 骞抽潰鎴块棿锛坖s/room2d.js锛夛細褰撹儗鏅摵鍦ㄧ珛缁樹笅闈紝涓嶆姠鎵嬪娍 */
.room2d-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
    z-index: 0;
    pointer-events: none;
}

.standee {
    position: absolute;
    width: 50px;
    height: 90px;
    border-radius: 25px;
    background-color: rgba(255, 255, 255, 0.08);
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center bottom;
    border: 2px solid rgba(212, 106, 147, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text);
    font-size: 13px;
    font-weight: 600;
    writing-mode: vertical-rl;
    text-orientation: upright;
    letter-spacing: 3px;
    user-select: none;
    pointer-events: auto;
    cursor: grab;
    touch-action: none;
    transition: box-shadow .2s, border-color .2s;
}

.standee:hover {
    box-shadow: 0 0 0 2px rgba(212, 106, 147, 0.5), 0 0 16px rgba(212, 106, 147, 0.5);
    border-color: rgba(212, 106, 147, 0.8);
}

.standee.dragging {
    cursor: grabbing;
    z-index: 10;
    box-shadow: 0 0 0 2px #C9A66B, 0 0 20px rgba(201, 166, 107, 0.6);
    border-color: #C9A66B;
}

@keyframes standeeWobble {

    0%,
    100% {
        transform: translateX(0) rotate(0deg);
    }

    25% {
        transform: translateX(-4px) rotate(-1deg);
    }

    50% {
        transform: translateX(0) rotate(0deg);
    }

    75% {
        transform: translateX(4px) rotate(1deg);
    }
}

.standee-player {
    border-color: #C9A66B;
    background-color: rgba(201, 166, 107, 0.12);
    box-shadow: 0 0 16px rgba(201, 166, 107, 0.35);
}

.location-card {
    width: 120px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 16px;
    padding: 16px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: 0.2s;
    backdrop-filter: blur(4px);
}

.location-card:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateY(-2px);
}

.location-card-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: 600;
}

.location-card-name {
    font-size: 13px;
    color: #ddd;
    text-align: center;
}

.location-empty-hint {
    color: #666;
    font-size: 14px;
}

.location-bottom {
    flex-shrink: 0;
    background: rgba(20, 12, 32, 0.85);
    backdrop-filter: blur(16px) saturate(160%);
    -webkit-backdrop-filter: blur(16px) saturate(160%);
    border-top: 1px solid rgba(212, 106, 147, 0.2);
    padding: 12px 20px 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.char-avatar-row {
    display: flex;
    gap: 10px;
    align-items: center;
    min-height: 44px;
}

.char-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(212, 106, 147, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    flex-shrink: 0;
    background-size: cover;
    background-position: center;
}

.char-avatar.dim {
    opacity: 0.3;
}

.char-avatar.player-slot {
    background: transparent;
    border: 1px dashed rgba(212, 106, 147, 0.4);
}

.char-avatar.lit {
    opacity: 1 !important;
    box-shadow: 0 0 0 2px #C9A66B, 0 0 14px rgba(201, 166, 107, 0.8);
    border-color: #C9A66B;
    transition: opacity .15s, box-shadow .15s, border-color .15s;
}

.speaker-name {
    color: var(--accent);
    font-size: 14px;
    font-weight: 600;
    padding-left: 4px;
    text-shadow: 0 0 12px rgba(201, 166, 107, 0.5);
}

.input-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.input-history-btn {
    width: 40px;
    height: 40px;
    background: rgba(30, 20, 45, 0.7);
    border: 1px solid rgba(212, 106, 147, 0.22);
    border-radius: 50%;
    font-size: 18px;
    cursor: pointer;
    color: var(--text);
    flex-shrink: 0;
    padding: 0;
    transition: all .2s;
}

.input-history-btn:hover {
    background: rgba(212, 106, 147, 0.18);
    border-color: rgba(212, 106, 147, 0.5);
    box-shadow: 0 0 14px rgba(212, 106, 147, 0.4);
}

.location-input {
    flex: 1;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(212, 106, 147, 0.2);
    border-radius: 20px;
    padding: 11px 16px;
    color: var(--text);
    font-size: 14px;
    outline: none;
    box-sizing: border-box;
    font-family: inherit;
    transition: border-color .2s, box-shadow .2s;
}

.location-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(212, 106, 147, 0.18);
}

.location-input::placeholder {
    color: var(--text-dim);
}

.input-send-btn {
    background: #D46A93;
    color: #fff;
    border: none;
    border-radius: 20px;
    padding: 11px 18px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    flex-shrink: 0;
    font-family: inherit;
    box-shadow: 0 4px 14px rgba(212, 106, 147, 0.35);
    transition: all .2s;
}

.input-send-btn:hover {
    box-shadow: 0 4px 20px rgba(201, 166, 107, 0.55);
    transform: translateY(-1px);
}

/* ===== 鍦扮偣鏂囧瓧鍖?路 瑙嗚灏忚鏍峰紡 ===== */
.text-display-area {
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    min-height: 120px;
    max-height: 200px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(212, 106, 147, 0.15);
    border-radius: 14px;
    padding: 14px 16px;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
    position: relative;
}

.vn-content {
    color: var(--text);
    font-size: 15px;
    line-height: 1.7;
    white-space: pre-wrap;
    word-break: break-word;
    flex: 1;
}
/* 鏃ラ棿鍗＄墖鏄祬鑹茬殑锛屾鏂囧緱鐢ㄦ繁瑜愯壊锛堝拰銆屾洿澶氥€嶈彍鍗曢噷鐨勫瓧鍚屼竴涓鑹诧級 */
html[data-mode="day"] .vn-content { color: #4A3A34; }

.vn-status {
    position: absolute;
    right: 14px;
    bottom: 10px;
    color: var(--accent);
    font-size: 13px;
    opacity: 0.85;
    pointer-events: none;
    text-shadow: 0 0 10px rgba(201, 166, 107, 0.6);
}

/* ===== 鐢熸垚涓攣瀹?UI ===== */
.scene-busy .location-icon-btn,
.scene-busy .location-capsule,
.scene-busy .standee,
.scene-busy .input-send-btn {
    pointer-events: none;
    opacity: 0.45;
    filter: saturate(0.6);
}

/* 璁板綍鎸夐挳涓嶉攣 */
.scene-busy .input-history-btn {
    pointer-events: auto;
    opacity: 1;
}

/* ===== 鍦扮偣璁板綍椤?===== */
.scene-record-page {
    position: fixed;
    inset: 0;
    background: #0f0a14;
    background-image:
        radial-gradient(circle at 15% 0%, rgba(169, 71, 109, 0.15), transparent 45%),
        radial-gradient(circle at 90% 100%, rgba(201, 166, 107, 0.10), transparent 50%);
    color: var(--text);
    z-index: 100;
    display: none;
    flex-direction: column;
}

.scene-record-page.active {
    display: flex;
}

.scene-record-header {
    display: flex;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}

.scene-record-back {
    font-size: 28px;
    cursor: pointer;
    color: var(--primary);
    padding: 0 12px 0 0;
    line-height: 1;
    transition: color .2s, text-shadow .2s;
}

.scene-record-back:hover {
    color: var(--accent);
    text-shadow: 0 0 12px rgba(201, 166, 107, 0.7);
}

.scene-record-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text);
}

.scene-record-list {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
}

.scene-record-group {
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px dashed rgba(212, 106, 147, 0.18);
}

.scene-record-group:last-child {
    border-bottom: none;
}

.scene-record-time {
    font-size: 12px;
    color: var(--text-dim);
    margin-bottom: 8px;
    letter-spacing: 0.3px;
}

.scene-record-line {
    font-size: 14px;
    line-height: 1.8;
    color: var(--text);
    margin-bottom: 2px;
    word-break: break-word;
}

.scene-record-role {
    color: var(--accent);
    font-weight: 600;
}

.scene-record-role.narration {
    color: var(--text-dim);
}

.scene-record-empty {
    text-align: center;
    color: var(--text-dim);
    padding: 60px 0;
    font-size: 14px;
}

/* ===== 璁板綍椤?路 鍒嗗壊绾?& 浜嬩欢鏉?===== */
.scene-record-divider {
    display: flex;
    align-items: center;
    margin: 24px 0 16px;
    gap: 12px;
}

.scene-record-divider::before,
.scene-record-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    opacity: 0.55;
}

.scene-record-divider span {
    font-size: 12px;
    color: var(--accent);
    opacity: 0.9;
    white-space: nowrap;
    letter-spacing: 0.5px;
    text-shadow: 0 0 10px rgba(201, 166, 107, 0.5);
}

.scene-record-event {
    color: var(--text-dim) !important;
    font-style: italic;
    font-size: 13px !important;
}

.scene-record-summary-btn {
    background: rgba(212, 106, 147, 0.12);
    border: 1px solid rgba(212, 106, 147, 0.3);
    border-radius: 12px;
    color: var(--primary);
    font-size: 14px;
    cursor: pointer;
    padding: 4px 14px;
    font-family: inherit;
    transition: all .2s;
}

.scene-record-summary-btn:hover {
    background: rgba(212, 106, 147, 0.22);
    border-color: rgba(212, 106, 147, 0.5);
    box-shadow: 0 0 12px rgba(212, 106, 147, 0.4);
}

.scene-record-summary-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}

/* ===== 鍙睍寮€鑳跺泭 & 灞曞紑琛?===== */
.location-capsule.expandable {
    border-style: dashed;
}

.location-capsule-arrow {
    margin-left: 4px;
    font-size: 10px;
    opacity: 0.85;
    display: inline-block;
}

.location-capsule.expanded {
    background: rgba(201, 166, 107, 0.25);
    border-color: rgba(201, 166, 107, 0.7);
    box-shadow: 0 0 14px rgba(201, 166, 107, 0.4);
}

.location-capsules-expanded {
    padding-top: 4px;
    flex-wrap: wrap;
    gap: 6px;
    justify-content: center;
}

.location-capsule-sub {
    font-size: 12px;
    padding: 4px 12px;
    background: rgba(15, 10, 20, 0.7);
    border: 1px solid rgba(212, 106, 147, 0.3);
}

.location-capsule-sub:hover {
    background: rgba(212, 106, 147, 0.22);
    border-color: rgba(212, 106, 147, 0.6);
}

/* ===== 鍦扮偣鐗╁搧鏍?===== */
.location-items-bar {
    padding: 8px 20px 0;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    flex-shrink: 0;
}

.location-item {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(212, 106, 147, 0.22);
    color: var(--text);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.15s;
    user-select: none;
    -webkit-user-select: none;
}

.location-item:hover {
    background: rgba(212, 106, 147, 0.16);
    border-color: rgba(212, 106, 147, 0.5);
    transform: translateY(-1px);
}

.location-item-broken {
    color: var(--accent);
    border-color: rgba(201, 166, 107, 0.4);
}

.location-items-empty {
    color: var(--text-dim);
    font-size: 13px;
}

.location-item-vanished {
    color: var(--text-dim);
    border-color: rgba(255, 255, 255, 0.08);
    text-decoration: line-through;
    opacity: 0.6;
}

.scene-record-summarizing-tag {
    display: inline-block;
    margin-left: 8px;
    padding: 1px 8px;
    font-size: 11px;
    color: var(--primary);
    background: rgba(212, 106, 147, 0.15);
    border: 1px solid rgba(212, 106, 147, 0.35);
    border-radius: 8px;
    vertical-align: middle;
    animation: summTagPulse 1.5s ease-in-out infinite;
}

@keyframes summTagPulse {

    0%,
    100% {
        opacity: 0.7;
    }

    50% {
        opacity: 1;
    }
}

/* ============================================================
   搴曢儴鍦烘櫙闈㈡澘
   ============================================================ */

.scene-bottom-panel {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    z-index: 10;
    overflow: visible;
}

.scene-text-area {
    position: relative;
    padding: 30px 20px 18px;
    display: flex;
    flex-direction: column;
    max-height: 55vh;
    overflow: visible;
    transition: max-height .35s ease, padding .3s ease, opacity .25s ease;
}

/* 鐜荤拑灞傦細瑙佸奖绾夸綅缃负瀹炶壊锛屽線涓嬫笎鍙樿繃娓″埌閫忔槑 */
.scene-glass-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    z-index: 0;

    background: rgba(15, 10, 20, 0.72);

    backdrop-filter: blur(18px) saturate(140%);
    -webkit-backdrop-filter: blur(18px) saturate(140%);
}

/* 澶村儚琛岋細鍚戜笂婧㈠嚭锛岃澶村儚涓嚎姝ｅソ钀藉湪闈㈡澘椤惰竟 = 瑙佸奖绾夸綅缃?*/
.scene-top-bar {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 16px;
    margin-top: 0;
    margin-bottom: 10px;
    min-height: 0;
    padding-left: 140px;
    /* 缁欑粷瀵瑰畾浣嶇殑澶村儚璁╁嚭宸﹁竟绌洪棿锛?2 + 16锛?*/
}

/* 澶村儚锛氱珫鐫€鐨勫渾瑙掔煩褰紝92脳120 */
.scene-avatar-wrap {
    position: absolute;
    left: 20px;
    top: -90px;
    /* 澶村儚涓績钀藉湪闈㈡澘椤惰竟锛堝悜涓婃孩鍑?60px = 120/2锛?*/
    width: 92px;
    height: 120px;
    border-radius: 30px;
    overflow: hidden;
    background: rgba(30, 20, 45, 0.9);
    border: 1.5px solid rgba(212, 106, 147, 0.22);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 8px rgba(212, 106, 147, 0.12);
    transition: border-color .3s, box-shadow .3s;
}

/* 褰撳唴閮ㄥご鍍?active 鏃讹紝澶栨璺熺潃浜?*/
.scene-avatar-wrap:has(.scene-avatar.active) {
    border-color: rgba(212, 106, 147, 0.85);
    box-shadow:
        0 0 20px rgba(212, 106, 147, 0.65),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.scene-avatar {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 42px;
    font-weight: 600;
    color: #fff;
    background-size: cover;
    background-position: center;
    font-family: 'WenJinMincho', 'Noto Serif SC', serif;
    /* 榛樿锛堟梺鐧芥椂锛夛細鏆?*/
    filter: brightness(0.4) saturate(0.35);
    opacity: 0.65;
    transition: filter .3s, opacity .3s;
}

.scene-avatar.active {
    /* 浜?*/
    filter: brightness(1) saturate(1);
    opacity: 1;
    box-shadow: inset 0 0 30px rgba(212, 106, 147, 0.45);
}

/* 鍚嶅瓧锛氬湴鍥惧乏涓婅"涓栫晫"鍚屽瓧浣撳悓鍙戝厜 */
.scene-name {
    position: relative;
    z-index: 2;
    font-family: 'WenJinMincho', 'Noto Serif SC', serif;
    font-size: 22px;
    font-weight: 500;
    color: #fff;
    letter-spacing: 2px;
    line-height: 1;
    flex-shrink: 0;
    text-shadow:
        0 0 12px rgba(255, 255, 255, 0.55),
        0 0 28px rgba(212, 106, 147, 0.35);
}

/* 瑙佸奖绾匡細鍙傝€冮椤?Dream 鏃佽竟閭ｆ潯绾?*/
.scene-line {
    flex: 1;
    height: 1px;
    margin-left: 16px;
    margin-right: 40px;
    background: linear-gradient(90deg,
            transparent 0%,
            rgba(212, 106, 147, 0.85) 50%,
            transparent 100%);
    box-shadow: 0 0 6px rgba(212, 106, 147, 0.45);
}

/* 鏂囨湰鍐呭鍖猴細閫忔槑鑳屾櫙锛岄潬鐜荤拑灞傚仛搴?*/
.scene-bottom-panel .text-display-area {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    min-height: 80px;
    max-height: 200px;
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 4px 4px 0;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
}

.scene-bottom-panel .text-display-area::-webkit-scrollbar {
    width: 3px;
}

.scene-bottom-panel .text-display-area::-webkit-scrollbar-thumb {
    background: rgba(212, 106, 147, 0.3);
    border-radius: 4px;
}

/* 杈撳叆鏍忥細鍙敼甯冨眬涓庡灞傝儗鏅紝瀛愬厓绱犳牱寮忎繚鎸佸師鏍?*/
.scene-input-bar {
    position: relative;
    z-index: 3;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px 16px;
    background: rgba(20, 12, 32, 0.85);
    backdrop-filter: blur(16px) saturate(160%);
    -webkit-backdrop-filter: blur(16px) saturate(160%);
    border-top: 1px solid rgba(212, 106, 147, 0.2);
    flex-shrink: 0;
}

/* ===== 鎶樺彔鎸夐挳 ===== */
.scene-fold-btn {
    position: absolute;
    right: 20px;
    top: 30px;
    z-index: 5;
    width: 26px;
    height: 26px;
    border: none;
    background: none;
    padding: 0;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: top .35s ease, color .2s, filter .2s;
}

.scene-fold-btn:hover {
    color: #fff;
    filter: drop-shadow(0 0 8px rgba(212, 106, 147, 0.9));
}

.scene-fold-btn .fold-svg {
    width: 20px;
    height: 20px;
    transition: transform .3s ease;
}

/* 鎶樺彔鐘舵€侊細鏂囨湰鍖烘敹璧蜂负 0锛屽彧鐣欒緭鍏ユ爮 */
.scene-bottom-panel.collapsed .scene-text-area {
    max-height: 0;
    padding-top: 0;
    padding-bottom: 0;
    opacity: 0;
    pointer-events: none;
    overflow: hidden;
}

/* 鎶樺彔鏃舵寜閽Щ鍒拌緭鍏ユ爮涓婃柟 */
.scene-bottom-panel.collapsed .scene-fold-btn {
    top: -30px;
}

/* 鎶樺彔鏃剁澶寸炕杞紝鏈濅笂 */
.scene-bottom-panel.collapsed .scene-fold-btn .fold-svg {
    transform: rotate(180deg) !important;
}

/* ===== 涓婚」鐩細缂栬緫鍣ㄧ墿鍝佸眰 ===== */
.location-items-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.location-items-layer .location-item-img {
    position: absolute;
    background-size: 100% 100%;
    background-repeat: no-repeat;
    image-rendering: pixelated;
}

.location-items-layer .location-item-img.state-gone {
    opacity: 0.4;
}

/* ===== 鎷栧姩骞界伒 ===== */
.standee-ghost {
    position: fixed !important;
    pointer-events: none !important;
    width: 50px;
    height: 90px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center bottom;
    border-radius: 25px;
    border: 2px solid #C9A66B;
    box-shadow: 0 0 20px rgba(201, 166, 107, 0.7);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    font-weight: 600;
    color: #fff;
    opacity: 0.85;
}
.standee-ghost.invalid {
    border-color: #f87171;
    box-shadow: 0 0 20px rgba(248, 113, 113, 0.7);
}
/* ===== 绔嬬粯閫変腑鐘舵€?===== */
.standee.selected {
    box-shadow: 0 0 0 2px #C9A66B, 0 0 20px rgba(201, 166, 107, 0.8);
    border-color: #C9A66B;
    z-index: 20;
}

/* ===== 绔嬬粯 8 涓墜鏌?===== */
.standee .standee-handle {
    position: absolute;
    width: 10px;
    height: 10px;
    background: #fff;
    border: 1.5px solid #C9A66B;
    border-radius: 50%;
    box-shadow: 0 0 6px rgba(201, 166, 107, 0.8);
    z-index: 30;
    box-sizing: border-box;
    pointer-events: auto;
}
.standee .standee-handle.h-tl { top: -5px; left: -5px; cursor: nwse-resize; }
.standee .standee-handle.h-tr { top: -5px; right: -5px; cursor: nesw-resize; }
.standee .standee-handle.h-bl { bottom: -5px; left: -5px; cursor: nesw-resize; }
.standee .standee-handle.h-br { bottom: -5px; right: -5px; cursor: nwse-resize; }
.standee .standee-handle.h-t { top: -5px; left: 50%; margin-left: -5px; cursor: ns-resize; }
.standee .standee-handle.h-b { bottom: -5px; left: 50%; margin-left: -5px; cursor: ns-resize; }
.standee .standee-handle.h-l { top: 50%; left: -5px; margin-top: -5px; cursor: ew-resize; }
.standee .standee-handle.h-r { top: 50%; right: -5px; margin-top: -5px; cursor: ew-resize; }

/* ===== 绔嬬粯鍙抽敭鑿滃崟 ===== */
.standee-menu {
    position: fixed;
    background: rgba(30, 20, 45, 0.95);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(212, 106, 147, 0.3);
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.6);
    z-index: 99999;
    padding: 4px 0;
    min-width: 140px;
    display: none;
}
.standee-menu.show { display: block; }
.standee-menu-item {
    display: block;
    width: 100%;
    padding: 10px 20px;
    background: none;
    border: none;
    color: var(--text);
    font-size: 14px;
    text-align: left;
    cursor: pointer;
    font-family: inherit;
    white-space: nowrap;
    transition: background .15s;
}
.standee-menu-item:hover {
    background: rgba(212, 106, 147, 0.15);
}
.standee-menu-item.danger {
    color: #fca5a5;
}
.standee-menu-item.danger:hover {
    background: rgba(239, 68, 68, 0.15);
}
/* ===== 绔嬬粯鍗犲湴鏍囨敞寮圭獥 ===== */
.footprint-hint {
    font-size: 12px;
    color: var(--text-dim);
    text-align: center;
    margin-bottom: 12px;
}
.footprint-wrap {
    display: flex;
    justify-content: center;
    align-items: center;
    max-height: 55vh;
    overflow: auto;
    background: #1a1325;
    border-radius: 8px;
    padding: 10px;
}
.footprint-canvas {
    position: relative;
    background-color: #2a1f3a;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center bottom;
    cursor: crosshair;
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
}
.footprint-select {
    position: absolute;
    border: 2px solid #34d399;
    background: rgba(52, 211, 153, 0.22);
    box-sizing: border-box;
    pointer-events: none;
    box-shadow: 0 0 10px rgba(52, 211, 153, 0.5);
}
/* ============================================================
   铏氭嫙鎽囨潌锛坢ove.js 鐢級
   ============================================================ */
.virtual-joystick {
    position: fixed;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: radial-gradient(circle,
        rgba(212, 106, 147, 0.14) 0%,
        rgba(212, 106, 147, 0.06) 100%);
    border: 1.5px solid rgba(212, 106, 147, 0.45);
    box-shadow: 0 0 20px rgba(212, 106, 147, 0.3);
    pointer-events: none;
    z-index: 100;
    transform: translate(-50%, -50%);
}

.virtual-joystick-knob {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: radial-gradient(circle,
        rgba(201, 166, 107, 0.7) 0%,
        rgba(212, 106, 147, 0.55) 100%);
    border: 1.5px solid rgba(255, 255, 255, 0.5);
    box-shadow: 0 0 16px rgba(201, 166, 107, 0.55);
    transform: translate(-50%, -50%);
}

/* 璧拌矾鏃剁珛缁樹笂涓嬫诞鍔?*/
.standee.walking {
    animation: standeeWalk 0.5s ease-in-out infinite;
}
@keyframes standeeWalk {
    0%, 100% { transform: translateY(0); }
    50%      { transform: translateY(-3px); }
}
/* ===== 鍦扮偣鍚嶆梺杈圭殑缂栬緫鎸夐挳 ===== */
.location-title-group {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}
.location-edit-btn {
    width: 34px;
    height: 34px;
    flex-shrink: 0;
}
.location-edit-btn .icon {
    width: 16px;
    height: 16px;
}
/* ===== 鏈夌珛缁樼殑瑙掕壊锛氳８鏄剧ず锛堟棤杈规銆佹棤搴曡壊銆佹棤鍦嗚锛?==== */
.standee.standee-has-img,
.standee.standee-has-img.selected {
    border: none !important;
    border-radius: 0 !important;
    background-color: transparent !important;
    box-shadow: none !important;
}
/* ===== 鍊欓€夊尯锛堝厹搴曪級===== */
.location-candidate-area {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    transform: translateY(100%);
    background: rgba(20, 12, 32, 0.85);
    border-top: 1px solid rgba(212, 106, 147, 0.25);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    padding: 10px 12px;
    gap: 10px;
    overflow: hidden;
    min-height: 0;
    box-sizing: border-box;
}
.candidate-list {
    display: flex;
    gap: 10px;
    align-items: center;
    flex: 1;
    min-height: 0;
    min-width: 0;
    overflow: hidden;
}
.candidate-item {
    width: 50px;
    height: 90px;
    flex-shrink: 0;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center bottom;
    background-color: transparent;
    border-radius: 25px;
    border: 2px solid rgba(212, 106, 147, 0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    font-weight: 600;
    color: var(--text);
    cursor: grab;
    user-select: none;
    -webkit-user-select: none;
    transition: transform .15s, border-color .15s, box-shadow .15s;
    box-sizing: border-box;
}
.candidate-item:hover {
    transform: scale(1.06);
    border-color: var(--primary);
    box-shadow: 0 0 14px rgba(212, 106, 147, 0.5);
}
.candidate-item:active {
    cursor: grabbing;
}
/* ============================================================
   瑙嗚灏忚闈㈡澘 路 鎵撶（ v2锛?026-11锛?
   鐩爣锛氱幓鐠冮潰鏉挎洿鍍忋€屽璇濇銆嶏紝鍚嶅瓧鏇村儚銆屽悕瀛楃銆嶏紝鏃ラ棿鍙
   ============================================================ */

/* 鐜荤拑锛氫笂瀹炰笅閫?+ 涓€閬撳唴楂樺厜 */
.scene-glass-bg {
    background: linear-gradient(180deg, rgba(16, 10, 24, .88) 0%, rgba(11, 7, 17, .93) 60%, rgba(8, 5, 13, .97) 100%);
    backdrop-filter: blur(18px) saturate(140%);
    -webkit-backdrop-filter: blur(18px) saturate(140%);
    box-shadow: inset 0 1px 0 rgba(246, 240, 244, .09);
}
html[data-mode="day"] .scene-glass-bg {
    background: linear-gradient(180deg, rgba(255, 255, 255, .95) 0%, rgba(252, 247, 242, .97) 60%, rgba(250, 244, 238, .99) 100%);
    box-shadow: inset 0 1px 0 rgba(36, 26, 34, .08);
}

/* 宸︿晶寮鸿皟绾匡細瀵硅瘽妗嗙殑銆屽満璁扮嚎銆?*/
.scene-text-area::before {
    content: "";
    position: absolute;
    left: 0; top: 14px; bottom: 14px;
    width: 2px;
    border-radius: 1px;
    background: linear-gradient(180deg, rgba(212, 106, 147, .85), rgba(212, 106, 147, .10));
    z-index: 2;
    pointer-events: none;
}
html[data-mode="day"] .scene-text-area::before {
    background: linear-gradient(180deg, rgba(178, 58, 102, .85), rgba(178, 58, 102, .10));
}

/* 璇磋瘽浜哄ご鍍忥細鏇村儚銆岀珛鍦ㄤ汉鏃佽竟銆嶈€屼笉鏄柟妗?*/
.scene-avatar-wrap {
    border-radius: 26px;
    background: rgba(22, 14, 30, .9);
    box-shadow: inset 0 0 0 1px rgba(246, 240, 244, .10),
                0 18px 40px -26px rgba(0, 0, 0, .95);
}
html[data-mode="day"] .scene-avatar-wrap {
    background: #FFFFFF;
    box-shadow: inset 0 0 0 1px rgba(36, 26, 34, .10),
                0 14px 30px -22px rgba(36, 26, 34, .45);
}

/* 鍚嶅瓧绛?*/
.scene-name {
    font-size: 11px;
    letter-spacing: .16em;
    color: var(--primary);
}
html[data-mode="day"] .scene-name { color: var(--day-accent); }

/* 鏂囨湰鍖猴細鍘绘帀鍐呭眰鍐嶅涓€灞傛鐨勬劅瑙?*/
.text-display-area {
    background: transparent;
    border: 0;
    border-radius: 0;
    padding: 6px 2px 4px;
}
.text-display-area:hover { background: transparent; }
html[data-mode="day"] .text-display-area { background: transparent; }

/* 鑸炲彴涓婄殑绔嬬粯锛氶粯璁や笉閫忔槑锛屽彧鏈夎璇濈殑閭ｅ嚑涓珮浜?*/
.standee { transition: opacity .25s ease, filter .25s ease; }
.standee:not(.speaking) { opacity: 1; filter: none; }
.standee.speaking {
    opacity: 1;
    filter: none;
    box-shadow: 0 0 0 2px rgba(212, 106, 147, .45), 0 0 22px rgba(212, 106, 147, .30);
}

/* 鏃ラ棿锛氶《鏍忎笌杈撳叆鏍忚窡鐫€鍙?*/
html[data-mode="day"] .location-page {
    background: #F5EFE9;
    background-image:
        radial-gradient(circle at 15% 0%, rgba(178, 58, 102, .08), transparent 45%),
        radial-gradient(circle at 90% 100%, rgba(169, 128, 63, .08), transparent 50%);
    color: var(--day-ink);
}
html[data-mode="day"] .location-icon-btn {
    background: rgba(255, 255, 255, .8);
    border-color: rgba(36, 26, 34, .10);
    color: var(--day-ink);
}
html[data-mode="day"] .scene-input-bar {
    background: rgba(250, 245, 240, .92);
    border-top-color: rgba(36, 26, 34, .08);
}
html[data-mode="day"] .location-input {
    background: #FFFFFF;
    border-color: rgba(36, 26, 34, .10);
    color: var(--day-ink);
}
html[data-mode="day"] .input-send-btn {
    background: linear-gradient(180deg, #C24A76, #A8335B);
    color: #FFF7F9;
}
/* ============================================================
   瑙嗚灏忚闈㈡澘 v3锛氫笉瑕佸ご鍍忥紝鍚嶅瓧鍋氭垚鑳跺泭鍘嬪湪闈㈡澘涓婃部
   璇磋瘽鐨勪汉锛氱珛缁?+ 鍚嶅瓧鑳跺泭涓€璧蜂寒
   ============================================================ */

/* 澶村儚涓嶅啀鏄剧ず锛堝厓绱犵暀鐫€锛宭ightSpeaker 杩樺湪鐢級 */
.scene-avatar-wrap { display: none !important; }

/* 鍚嶅瓧琛屽彉鎴愩€屽帇鍦ㄦ涓婃部鐨勮兌鍥娿€?*/
.scene-top-bar {
    position: absolute;
    top: -13px;
    left: 16px;
    z-index: 4;
    display: block;
    margin: 0;
    padding: 0;
    min-height: 0;
}
.scene-top-bar .scene-line { display: none; }
.scene-name {
    display: inline-flex;
    align-items: center;
    height: 26px;
    padding: 0 14px;
    border-radius: 13px;
    font-size: 10.5px;
    letter-spacing: .16em;
    color: #1B0C14;
    background: linear-gradient(180deg, #E07BA2, #C4577F);
    box-shadow: 0 10px 22px -12px rgba(212, 106, 147, .85), inset 0 1px 0 rgba(255, 255, 255, .25);
    writing-mode: horizontal-tb;
    text-orientation: mixed;
    white-space: nowrap;
    line-height: 1;
}
.scene-name.narrator {
    color: var(--accent);
    background: rgba(201, 166, 107, .14);
    box-shadow: inset 0 0 0 1px rgba(201, 166, 107, .35);
}
html[data-mode="day"] .scene-name {
    background: linear-gradient(180deg, #C24A76, #A8335B);
    color: #FFF7F9;
    box-shadow: 0 10px 20px -12px rgba(168, 51, 91, .6);
}
html[data-mode="day"] .scene-name.narrator {
    color: #7E5C22;
    background: rgba(169, 128, 63, .14);
    box-shadow: inset 0 0 0 1px rgba(169, 128, 63, .30);
}

/* 鏂囨湰鍖猴細缁欒兌鍥婅鍑轰笂杈硅窛 */
.scene-text-area { padding-top: 26px; }/* 鏃ラ棿锛氳褰曟寜閽?/ 杈撳叆妗嗗埆鏄粦鐨?*/
html[data-mode="day"] .input-history-btn {
    background: transparent;
    color: var(--day-dim);
    border-color: transparent;
}
html[data-mode="day"] .input-history-btn svg { color: var(--day-dim); }
html[data-mode="day"] .input-history-btn:hover { background: rgba(36, 26, 34, .05); }
/* ============================================================
   閰嶈壊瀹氱锛坴4锛夛細绮?/ 閲?/ 鐧斤紝涓夎壊涓€濂?
   瑙掕壊 = 绮夊簳鐧藉瓧锛涙梺鐧?= 閲戝簳鐧藉瓧锛涚敤鎴?= 鐧藉簳閲戝瓧
   绔嬬粯鍚嶅瓧 = 鐧藉簳锛岃鑹茬矇瀛?/ 鐢ㄦ埛閲戝瓧锛涜璇濇椂鍙嶈繃鏉?
   ============================================================ */

/* 闈㈡澘涓婄殑鍚嶅瓧鑳跺泭锛氫笉瑕佸崐閫忔槑搴曪紝瀹炶壊 */
.scene-name,
.scene-name.narrator,
.scene-name.player {
    background: #D46A93;
    color: #FFFFFF;
    box-shadow: 0 8px 18px -12px rgba(0, 0, 0, .5);
    border: 0;
}
.scene-name.narrator {
    background: #C9A66B;
    color: #FFFFFF;
}
.scene-name.player {
    background: #FFFFFF;
    color: #C9A66B;
    box-shadow: inset 0 0 0 1px rgba(201, 166, 107, .45);
}
/* 鐢ㄦ埛鍙戣█锛堟鍦ㄥ洖搴旓級锛氶噾搴曠櫧瀛?*/
.scene-name.player.speaking {
    background: #C9A66B;
    color: #FFFFFF;
    box-shadow: 0 8px 18px -10px rgba(201, 166, 107, .7);
}
/* 瑙掕壊鍙戣█鏃讹細绮夊簳鐧藉瓧锛堥粯璁ゅ氨鏄級锛屼繚鐣欎竴涓槑纭€?*/
.scene-name.speaking { background: #D46A93; color: #FFFFFF; }
.scene-name.narrator.speaking { background: #C9A66B; color: #FFFFFF; }

/* 绔嬬粯涓嬮潰鐨勫悕瀛楋細妯帓锛涚櫧搴曪紝瑙掕壊绮夊瓧 */
.standee-name {
    writing-mode: horizontal-tb;
    text-orientation: mixed;
    letter-spacing: 0;
    font-size: 12px;
}
/* ============================================================
   绔嬬粯鍚嶅瓧鑳跺泭锛堝叏椤圭洰鍙涓€澶勶紝鍒涓嶈鍐嶅姞瑙勫垯锛?
   瑙掕壊锛氱櫧搴曠矇瀛?鈫?璇磋瘽绮夊簳鐧藉瓧
   鐢ㄦ埛锛氱櫧搴曢妲熼噾 鈫?璇磋瘽棣欐閲戝簳鐧藉瓧
   ============================================================ */
.standee-plate {
    position: absolute; left: 50%; bottom: -20px; transform: translateX(-50%);
    padding: 2px 9px; border-radius: 9px;
    font-size: 10px; letter-spacing: .1em; white-space: nowrap;
    writing-mode: horizontal-tb; text-orientation: mixed;
    color: #D46A93; background: #FFFFFF;
    box-shadow: inset 0 0 0 1px rgba(212, 106, 147, .25);
    pointer-events: none;
    transition: color .2s, background .2s, box-shadow .2s;
}
.standee.standee-player .standee-plate {
    color: #C9A66B; background: #FFFFFF;
    box-shadow: inset 0 0 0 1px rgba(201, 166, 107, .45);
}
.standee.speaking .standee-plate {
    color: #FFFFFF; background: #D46A93;
    box-shadow: 0 0 16px rgba(212, 106, 147, .55);
}
.standee.standee-player.speaking .standee-plate {
    color: #FFFFFF; background: #C9A66B;
    box-shadow: 0 0 16px rgba(201, 166, 107, .55);
}
html[data-mode="day"] .standee .standee-plate {
    color: #B23A66; background: #FFFFFF;
    box-shadow: inset 0 0 0 1px rgba(178, 58, 102, .22);
}
html[data-mode="day"] .standee.speaking .standee-plate {
    color: #FFFFFF; background: #B23A66;
}
html[data-mode="day"] .standee.standee-player .standee-plate {
    color: #A9803F; background: #FFFFFF;
    box-shadow: inset 0 0 0 1px rgba(169, 128, 63, .32);
}
html[data-mode="day"] .standee.standee-player.speaking .standee-plate {
    color: #FFFFFF; background: #A9803F;
}
html[data-mode="day"] .scene-name.player {
    background: #FFFFFF;
    color: #A9803F;
    box-shadow: inset 0 0 0 1px rgba(169, 128, 63, .40);
}/* ============================================================
   鐜╁绉诲姩锛氳櫄鎷熸憞鏉?
   ============================================================ */
.walk-stick {
    position: absolute;
    width: 72px; height: 72px;
    margin: -36px 0 0 -36px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(246,240,244,.10), rgba(246,240,244,.04) 70%, transparent 72%);
    box-shadow: inset 0 0 0 1px rgba(246,240,244,.18);
    pointer-events: none;
    opacity: 0;
    transition: opacity .12s ease;
    z-index: 12;
}
.walk-stick.on { opacity: 1; }
.walk-knob {
    position: absolute;
    left: 50%; top: 50%;
    width: 30px; height: 30px;
    border-radius: 50%;
    background: linear-gradient(180deg, rgba(246,240,244,.9), rgba(214,206,216,.75));
    box-shadow: 0 6px 16px -6px rgba(0,0,0,.7);
    transform: translate(-50%, -50%);
}
html[data-mode="day"] .walk-stick {
    background: radial-gradient(circle, rgba(36,26,34,.10), rgba(36,26,34,.04) 70%, transparent 72%);
    box-shadow: inset 0 0 0 1px rgba(36,26,34,.18);
}
html[data-mode="day"] .walk-knob {
    background: linear-gradient(180deg, #FFFFFF, #E6DCD2);
    box-shadow: 0 6px 16px -6px rgba(36,26,34,.45);
}
/* ============================================================
   鍦扮偣椤碉細3D 鑸炲彴 / 鍦烘櫙妯″紡 / 鏂囨湰鍗＄墖
   杩欎竴鍧楁槸鍞竴鏉ユ簮锛屼笉瑕佸啀寰€涓婂彔瑕嗙洊
   ============================================================ */

/* ---- 鑸炲彴搴曡壊锛氭棩娴呭娣?---- */
.location-stage { background: #221A1F; }
html[data-mode="day"] .location-stage { background: #E9DFCF; }
.room3d-canvas { touch-action: none; -webkit-user-select: none; user-select: none; }

/* ---- 椤堕儴锛氭ā寮忓垏鎹?+ 鏇村 ---- */
.location-topbar { position: relative; padding: 14px 14px 10px; }
.location-title { max-width: 156px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.location-actions { flex-shrink: 0; gap: 6px; }
.loc-mode-seg {
    display: inline-flex; align-items: center; padding: 3px; border-radius: 17px;
    background: rgba(255, 255, 255, .055); border: 1px solid rgba(212, 106, 147, .26);
}
.loc-seg-btn {
    border: 0; background: transparent; color: rgba(241, 226, 210, .6);
    font-size: 11.5px; height: 28px; padding: 0 7px; border-radius: 14px; line-height: 28px;
}
.loc-seg-btn.on { background: rgba(212, 106, 147, .3); color: #F9EDE0; }
.loc-more-btn {
    width: 34px; height: 34px; font-size: 16px; line-height: 1; padding: 0;
    display: flex; align-items: center; justify-content: center;
}
.loc-pop {
    position: absolute; top: 58px; right: 14px; min-width: 172px; padding: 8px;
    border-radius: 14px; display: none; z-index: 30;
    background: rgba(30, 21, 26, .96); border: 1px solid rgba(212, 106, 147, .28);
    box-shadow: 0 14px 34px rgba(0, 0, 0, .55);
    -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
}
.loc-pop.show { display: block; }
.loc-pop-title { font-size: 10px; color: rgba(241, 226, 210, .45); letter-spacing: 1.5px; padding: 4px 10px 6px; }
.loc-pop-row {
    display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 10px;
    border: 0; border-radius: 9px; background: transparent; color: #EFE0D0;
    font-size: 13.5px; text-align: left;
}
.loc-pop-row:active { background: rgba(255, 255, 255, .07); }
.loc-pop-row .icon { width: 15px; height: 15px; opacity: .78; flex-shrink: 0; }

/* 绠€鏄撴ā寮忛《閮ㄥ悓鏍蜂竴濂?*/
.fs-top { position: relative; }
.fs-more-btn {
    width: 34px; height: 34px; font-size: 16px; display: flex;
    align-items: center; justify-content: center; padding: 0; line-height: 1;
}
#fsMorePop { top: 56px; right: 12px; }

/* ---- 3D 鍚嶅瓧鑳跺泭锛氱櫧搴曠矇瀛?鈫?璇磋瘽绮夊簳鐧藉瓧 ---- */
.room3d-labels { position: absolute; inset: 0; pointer-events: none; overflow: hidden; z-index: 4; }
.room3d-label {
    position: absolute; left: 0; top: 0; transform: translate(-50%, -100%);
    padding: 2px 9px; border-radius: 10px; font-size: 11px; line-height: 16px;
    white-space: nowrap; background: #FFFFFF; color: #D46A93;
    cursor: pointer; pointer-events: auto;
    border: 1px solid rgba(212, 106, 147, .35);
    box-shadow: 0 3px 10px rgba(0, 0, 0, .25); will-change: transform;
    transition: background .18s, color .18s, box-shadow .18s;
}
.room3d-label.speaking {
    background: #D46A93; color: #FFFFFF;
    box-shadow: 0 0 14px rgba(212, 106, 147, .55);
}
/* 3D 閲岀帺瀹惰嚜宸辩殑鍚嶅瓧鑳跺泭锛氱櫧搴曢妲熼噾 鈫?璇磋瘽棣欐閲戝簳鐧藉瓧 */
.room3d-label.room3d-label-player {
    color: #C9A66B; background: #FFFFFF;
    border-color: rgba(201, 166, 107, .45);
}
.room3d-label.room3d-label-player.speaking {
    background: #C9A66B; color: #FFFFFF;
    border-color: rgba(201, 166, 107, .6);
    box-shadow: 0 0 14px rgba(201, 166, 107, .55);
}

/* ---- 3D 甯冪疆闈㈡澘 ---- */
.room3d-edit {
    position: absolute; left: 10px; right: 10px; bottom: 10px; z-index: 20;
    display: none; padding: 10px 12px; border-radius: 16px;
    background: rgba(28, 19, 24, .94); border: 1px solid rgba(212, 106, 147, .3);
    box-shadow: 0 12px 30px rgba(0, 0, 0, .5);
}
.room3d-edit.show { display: block; }
.r3e-title { font-size: 11px; letter-spacing: 1.5px; color: rgba(241, 226, 210, .5); margin-bottom: 8px; }
.r3e-hint { font-size: 11px; color: rgba(241, 226, 210, .42); margin: -3px 0 8px; }
.r3e-items { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 6px; }
.r3e-sep {
    align-self: center; flex: 0 0 auto; font-size: 11px; color: rgba(241, 226, 210, .34);
    padding: 0 2px 0 4px; letter-spacing: 1px;
}
.r3e-items button, .r3e-actions button {
    border: 1px solid rgba(255, 255, 255, .14); background: rgba(255, 255, 255, .06);
    color: #EFE0D0; font-size: 12px; padding: 6px 10px; border-radius: 10px; white-space: nowrap;
}
.r3e-actions { display: flex; gap: 6px; margin-top: 6px; }
.r3e-actions [data-act="done"] {
    margin-left: auto; background: rgba(212, 106, 147, .28); border-color: rgba(212, 106, 147, .55);
}

/* ---- 鏂囨湰鍗＄墖锛氳创杈硅创搴曪紝鍙湁涓婃柟鍦嗚 ---- */
.scene-bottom-panel { left: 0; right: 0; bottom: 0; padding: 0 !important; -webkit-tap-highlight-color: transparent; }
.scene-bottom-panel::before, .scene-bottom-panel::after { display: none !important; content: none !important; }
.scene-text-area, .scene-text-area::before, .scene-text-area::after { -webkit-tap-highlight-color: transparent; }
.scene-text-area::before, .scene-text-area::after { display: none !important; content: none !important; }
.scene-text-area {
    position: relative; overflow: visible !important;
    border-radius: 20px 20px 0 0 !important;
    border: 0 !important; border-top: 1px solid rgba(255, 255, 255, .06) !important;
    background: #1B1418 !important; background-image: none !important;
    box-shadow: 0 -10px 30px rgba(0, 0, 0, .35) !important;
    padding: 20px 16px 10px !important;
}
/* 鐜荤拑灞備笉瑕佸啀鐩栦竴灞傦細鏃㈠涓€灞傦紝鍙堟槸鍏ㄥ backdrop blur锛?D 涓嬮潰鍗￠】鐨勫厓鍑讹級 */
.scene-glass-bg { display: none !important; }
/* 鏃ラ棿锛氭枃鏈鍥炲埌娴呰壊鍗＄墖锛堜笉鏄闂撮偅濂楁繁鑹诧級 */
html[data-mode="day"] .scene-text-area {
    background: #FBF4E6 !important;
    border-top-color: rgba(120, 90, 70, .12) !important;
    box-shadow: 0 -10px 26px rgba(120, 90, 70, .12) !important;
}
html[data-mode="day"] .scene-text-area .text-display-area { color: #4A3A34 !important; }
.scene-text-area .scene-avatar-wrap { display: none !important; }
.scene-text-area .scene-top-bar {
    position: absolute !important; top: 0 !important; left: 16px !important;
    margin: 0 !important; padding: 0 !important; transform: translateY(-50%) !important;
    z-index: 5; display: block !important; height: auto !important;
}
.scene-text-area .scene-line { display: none !important; }
/* 璇磋瘽浜鸿兌鍥婏細鎭掑畾褰╁簳鐧藉瓧锛屼笉闅忚璇濆彉 */
.scene-text-area .scene-name {
    display: inline-block !important; padding: 3px 12px !important;
    border-radius: 12px !important; font-size: 12px !important; line-height: 18px !important;
    letter-spacing: .5px !important; color: #FFFFFF !important;
    background: #D46A93 !important; background-image: none !important;
    border: 1px solid rgba(255, 255, 255, .18) !important;
    box-shadow: 0 4px 14px rgba(0, 0, 0, .32) !important;
}
.scene-text-area .scene-name.narrator,
.scene-text-area .scene-name.player { background: #C9A66B !important; }
html[data-mode="day"] .scene-text-area .scene-name { background: #D46A93 !important; color: #fff !important; }
html[data-mode="day"] .scene-text-area .scene-name.narrator,
html[data-mode="day"] .scene-text-area .scene-name.player { background: #C9A66B !important; color: #fff !important; }
.scene-text-area .text-display-area { -webkit-user-select: none; user-select: none; color: #CBBBA9; }
.scene-text-area .text-display-area:hover,
.scene-text-area .text-display-area:active { background: transparent; }

/* 灞曞紑/鏀惰捣锛氫竴鏉℃殫鑹叉帴缂?*/
.scene-fold-btn {
    position: absolute !important; left: 50% !important; right: auto !important;
    top: 12px !important; bottom: auto !important; transform: translateX(-50%) !important;
    width: 34px !important; height: 3px !important; border-radius: 2px !important;
    padding: 0 !important; border: 0 !important; box-shadow: none !important;
    background: #3F3238 !important; opacity: 1 !important;
}
.scene-fold-btn svg { display: none !important; }
html[data-mode="day"] .scene-fold-btn { background: #C3AE94 !important; }

/* 杈撳叆鏍忎笌鍗＄墖鍚岃壊 */
.scene-input-bar {
    background: #1B1418 !important; border-top: 1px solid rgba(255, 255, 255, .05) !important;
}
html[data-mode="day"] .scene-input-bar {
    background: #FBF4E6 !important; border-top-color: rgba(120, 90, 70, .12) !important;
}

/* ---- 绔嬬粯鍚嶅瓧妗嗭細鐧藉簳褰╁瓧 鈫?璇磋瘽褰╁簳鐧藉瓧 ----
   娉ㄦ剰锛氳繖浜涚櫧搴曞彧缁欍€屾病鏈夌珛缁樺浘鐨勫崰浣嶆柟鍧椼€嶇敤銆?
   鏈?PNG 绔嬬粯鐨勫繀椤讳繚鎸佽儗鏅€忔槑锛屽惁鍒欐墸濂界殑閫忔槑搴曚細琚埛鎴愪竴鍧楃櫧銆?*/
.standee:not(.standee-has-img) { background-color: #FFFFFF !important; color: #D46A93 !important; border-color: rgba(212, 106, 147, .45) !important; }
.standee.standee-player:not(.standee-has-img) { color: #B08A4E !important; border-color: rgba(201, 166, 107, .5) !important; }
.standee.speaking:not(.standee-has-img) { background-color: #D46A93 !important; color: #FFFFFF !important; }
.standee.standee-player.speaking:not(.standee-has-img) { background-color: #C9A66B !important; color: #FFFFFF !important; }
/* ---- 绔嬬粯鍚嶅瓧妗嗭細鐢ㄦ埛=鐧藉簳棣欐瀛?鈫?璇磋瘽棣欐搴曠櫧瀛?---- */
.standee.standee-player:not(.standee-has-img) { background-color: #FFFFFF !important; color: #B08A4E !important; border-color: rgba(201, 166, 107, .55) !important; }
.standee.standee-player.speaking:not(.standee-has-img) { background-color: #C9A66B !important; color: #FFFFFF !important; }
/* 鏈夌珛缁樺浘鐨勶細纭繚閫忔槑锛堣繖閲屽啀鍏滀竴娆″簳锛岄槻姝㈠埆鐨?!important 鎶級 */
.standee.standee-has-img,
.standee.standee-has-img.speaking,
.standee.standee-player.standee-has-img,
.standee.standee-player.standee-has-img.speaking {
    background-color: transparent !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
}

/* ---- 娴呰壊妯″紡閫傞厤 ---- */
html[data-mode="day"] .loc-mode-seg { background: rgba(0, 0, 0, .04); border-color: rgba(180, 120, 100, .30); }
html[data-mode="day"] .loc-seg-btn { color: rgba(80, 60, 55, .62); }
html[data-mode="day"] .loc-seg-btn.on { background: rgba(212, 106, 147, .20); color: #7C3A52; }
html[data-mode="day"] .loc-more-btn { color: #6B564E; }
html[data-mode="day"] .location-title { color: #3A2C27; }
html[data-mode="day"] .loc-pop {
    background: #FFFDF8; border-color: rgba(180, 120, 100, .28);
    box-shadow: 0 14px 34px rgba(120, 90, 70, .18);
}
html[data-mode="day"] .loc-pop-title { color: rgba(90, 70, 60, .55); }
html[data-mode="day"] .loc-pop-row { color: #4A3A34; }
html[data-mode="day"] .loc-pop-row:active { background: rgba(0, 0, 0, .05); }
html[data-mode="day"] .text-display-area,
html[data-mode="day"] .scene-text-area .text-display-area { color: #4A3A34 !important; }
html[data-mode="day"] .scene-text-area .scene-name { color: #FFFFFF !important; }
html[data-mode="day"] .scene-input-bar .location-input { color: #4A3A34; }
html[data-mode="day"] .scene-input-bar .location-input::placeholder { color: rgba(90, 70, 60, .45); }
/* 瑙掕壊韬珮琛?*/
.r3e-chars { display: flex; flex-direction: column; gap: 4px; margin: 6px 0 2px; }
.r3e-char {
    display: flex; align-items: center; gap: 8px;
    padding: 4px 8px; border-radius: 9px; background: rgba(255, 255, 255, .04);
    color: #EFE0D0; font-size: 12px;
}
.r3e-cname { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.r3e-char button {
    width: 24px; height: 24px; border-radius: 8px; padding: 0;
    border: 1px solid rgba(255, 255, 255, .14); background: rgba(255, 255, 255, .07);
    color: #EFE0D0; font-size: 13px; line-height: 1;
}
.r3e-hv { width: 38px; text-align: center; font-weight: 600; color: #F4C7D8; }
/* 鍥哄畾宸︿笅瑙掓憞鏉嗭細2D / 3D 鍏辩敤锛屼笉鍐嶈窡鐫€鎵嬫寚鐢熸垚 */
.scene-joystick {
    position: fixed;
    left: max(16px, env(safe-area-inset-left));
    bottom: calc(env(safe-area-inset-bottom) + 112px);
    width: 112px;
    height: 112px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(212,106,147,.18), rgba(212,106,147,.06) 70%, transparent 72%);
    border: 1.5px solid rgba(212,106,147,.45);
    box-shadow: 0 0 24px rgba(212,106,147,.22);
    z-index: 9;
    touch-action: none;
    user-select: none;
    -webkit-user-select: none;
}
.scene-joystick-knob {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(201,166,107,.78), rgba(212,106,147,.62));
    border: 1.5px solid rgba(255,255,255,.5);
    box-shadow: 0 6px 18px -6px rgba(0,0,0,.55);
    transform: translate(-50%, -50%);
    pointer-events: none;
}
html[data-mode="day"] .scene-joystick {
    background: radial-gradient(circle, rgba(36,26,34,.10), rgba(36,26,34,.03) 70%, transparent 72%);
    border-color: rgba(36,26,34,.28);
    box-shadow: 0 0 20px rgba(36,26,34,.10);
}
html[data-mode="day"] .scene-joystick-knob {
    background: radial-gradient(circle, #FFFFFF, #E6DCD2);
    border-color: rgba(36,26,34,.30);
}

/* ===== 角色形象：列表 + 2D/3D 设置 ===== */
.chlook-panel {
    --lp-bg: rgba(26,18,24,.975);
    --lp-fg: #F6F0F4;
    --lp-muted: #BCA8B2;
    --lp-line: rgba(255,255,255,.11);
    --lp-soft: rgba(255,255,255,.055);
    --lp-soft2: rgba(255,255,255,.10);
    --lp-accent: #D46A93;
    --lp-accent-soft: rgba(212,106,147,.20);
    --lp-stage: rgba(0,0,0,.22);
    position: fixed;
    inset: 0;
    z-index: 960;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 18px;
    background: rgba(12,8,11,.52);
    -webkit-backdrop-filter: blur(3px);
    backdrop-filter: blur(3px);
    font-size: 13px;
    color: var(--lp-fg);
}
.chlook-panel.show { display: flex; }
.chlook-card {
    width: min(640px, 100%);
    max-height: min(780px, calc(100dvh - 36px));
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-radius: 22px;
    border: 1px solid rgba(212,106,147,.22);
    background: var(--lp-bg);
    color: var(--lp-fg);
    box-shadow: 0 30px 80px rgba(0,0,0,.52), 0 0 0 1px rgba(255,255,255,.03) inset;
}
.chlook-panel.show .chlook-card { animation: lookCardIn .18s ease-out; }
@keyframes lookCardIn {
    from { opacity: 0; transform: translateY(8px) scale(.985); }
    to { opacity: 1; transform: none; }
}
.chlook-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px 12px;
    border-bottom: 1px solid var(--lp-line);
}
.chlook-head-left { display: flex; align-items: center; gap: 8px; min-width: 0; }
.chlook-back {
    width: 30px; height: 30px; flex: none;
    display: none; align-items: center; justify-content: center;
    padding: 0;
    border-radius: 9px;
    border: 1px solid var(--lp-line);
    background: transparent;
    color: var(--lp-muted);
    cursor: pointer;
}
.chlook-back svg { width: 17px; height: 17px; }
.chlook-back:hover { color: var(--lp-fg); border-color: rgba(212,106,147,.5); }
.chlook-panel.chlook-in-edit .chlook-back { display: inline-flex; }
.chlook-title { font-size: 15px; font-weight: 600; letter-spacing: .04em; }
.chlook-sub { margin-top: 3px; font-size: 11px; color: var(--lp-muted); }
.chlook-close {
    width: 32px; height: 32px; flex: none;
    display: flex; align-items: center; justify-content: center;
    border-radius: 50%;
    border: 1px solid var(--lp-line);
    background: transparent;
    color: var(--lp-muted);
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
}
.chlook-close:hover { color: var(--lp-fg); border-color: rgba(212,106,147,.5); }
.chlook-body {
    flex: 1;
    min-height: 0;
    overflow: auto;
    padding: 12px 16px 16px;
    -webkit-overflow-scrolling: touch;
}
.chlook-panel .chlook-view { display: none; }
.chlook-panel:not(.chlook-in-edit) #chlookListView { display: block; }
.chlook-panel.chlook-in-edit #chlookEditView { display: block; }

/* 列表 */
.chlook-list { display: flex; flex-direction: column; gap: 8px; }
.chlook-row {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 9px 10px;
    border-radius: 14px;
    border: 1px solid transparent;
    background: var(--lp-soft);
    cursor: pointer;
    transition: background .15s, border-color .15s;
}
.chlook-row:hover { background: var(--lp-soft2); }
.chlook-row.active { border-color: rgba(212,106,147,.45); }
.chlook-ava {
    width: 42px; height: 42px; flex: none;
    display: flex; align-items: center; justify-content: center;
    overflow: hidden;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(212,106,147,.35), rgba(120,90,140,.35));
    color: #fff;
    font-size: 16px;
    font-weight: 600;
}
.chlook-ava img { width: 100%; height: 100%; object-fit: cover; display: block; }
.chlook-id { flex: 1; min-width: 0; }
.chlook-name {
    font-size: 14px; line-height: 1.2;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.chlook-name em {
    font-style: normal;
    font-size: 10px;
    padding: 1px 6px;
    margin-left: 6px;
    border-radius: 99px;
    background: var(--lp-accent-soft);
    color: var(--lp-accent);
    vertical-align: 1px;
}
.chlook-mode { margin-top: 3px; font-size: 11px; color: var(--lp-muted); }
.chlook-btns { display: flex; align-items: center; gap: 5px; flex: none; }
.chlook-icon {
    width: 32px; height: 30px;
    display: inline-flex; align-items: center; justify-content: center;
    padding: 0;
    border-radius: 9px;
    border: 1px solid var(--lp-line);
    background: transparent;
    color: var(--lp-muted);
    cursor: pointer;
}
.chlook-icon svg { width: 16px; height: 16px; }
.chlook-icon:hover { color: var(--lp-fg); border-color: rgba(212,106,147,.5); }
.chlook-seg {
    min-width: 34px; height: 30px;
    padding: 0 8px;
    border-radius: 9px;
    border: 1px solid var(--lp-line);
    background: transparent;
    color: var(--lp-muted);
    font-family: inherit;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .02em;
    cursor: pointer;
}
.chlook-seg:hover { color: var(--lp-fg); }
.chlook-seg.on {
    background: var(--lp-accent-soft);
    border-color: rgba(212,106,147,.62);
    color: #fff;
}

/* 设置页 */
.chlook-editor { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.chlook-pane { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.chlook-pane-head {
    display: flex; align-items: center; justify-content: space-between; gap: 6px;
    font-size: 12px; letter-spacing: .05em; color: var(--lp-muted);
}
.chlook-badge {
    font-weight: 500;
    font-size: 10px;
    padding: 2px 7px;
    border-radius: 99px;
    border: 1px solid var(--lp-line);
    color: var(--lp-muted);
    opacity: .5;
}
.chlook-badge.on {
    opacity: 1;
    color: var(--lp-accent);
    border-color: rgba(212,106,147,.5);
    background: var(--lp-accent-soft);
}
.chlook-stage {
    position: relative;
    height: 268px;
    display: flex; align-items: center; justify-content: center;
    overflow: hidden;
    border-radius: 14px;
    border: 1px solid var(--lp-line);
    background: var(--lp-stage);
}
.chlook-stage img { max-width: 100%; max-height: 100%; object-fit: contain; display: block; }
.chlook-empty { font-size: 12px; color: var(--lp-muted); opacity: .7; }
.chlook-stage-3d {
    background:
        radial-gradient(120% 78% at 50% 94%, rgba(212,106,147,.16) 0%, rgba(0,0,0,0) 62%),
        var(--lp-stage);
}
#chlook3dCanvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.chlook-3d-status {
    position: absolute; left: 0; right: 0; top: 50%;
    transform: translateY(-50%);
    text-align: center;
    font-size: 11px;
    color: var(--lp-muted);
    pointer-events: none;
}
.chlook-3d-status.hide { display: none; }
.chlook-tools { display: flex; gap: 6px; }
.chlook-file {
    flex: 1;
    position: relative;
    display: flex; align-items: center; justify-content: center;
    height: 32px;
    border-radius: 9px;
    border: 1px dashed rgba(255,255,255,.22);
    color: var(--lp-muted);
    font-size: 12px;
    cursor: pointer;
}
.chlook-file:hover { border-color: rgba(212,106,147,.6); color: var(--lp-fg); }
.chlook-file input { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
.chlook-ghost {
    height: 32px;
    padding: 0 11px;
    border-radius: 9px;
    border: 1px solid var(--lp-line);
    background: transparent;
    color: var(--lp-muted);
    font-family: inherit;
    font-size: 12px;
    cursor: pointer;
}
.chlook-ghost:hover { color: var(--lp-fg); border-color: rgba(212,106,147,.5); }
.chlook-swatches { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.chlook-swatch {
    display: flex; align-items: center; gap: 7px;
    height: 32px;
    padding: 0 9px;
    border-radius: 9px;
    border: 1px solid var(--lp-line);
    background: transparent;
    color: var(--lp-muted);
    font-family: inherit;
    font-size: 11px;
    text-align: left;
    cursor: pointer;
}
.chlook-swatch i {
    width: 14px; height: 14px; flex: none;
    border-radius: 50%;
    box-shadow: 0 0 0 1px rgba(255,255,255,.22) inset;
}
.chlook-swatch span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chlook-swatch:hover { color: var(--lp-fg); }
.chlook-swatch.on {
    border-color: rgba(212,106,147,.62);
    background: var(--lp-accent-soft);
    color: var(--lp-fg);
}

/* 装扮 */
.chlook-outfits {
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid var(--lp-line);
}
.chlook-outfits-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
    font-size: 12px;
    letter-spacing: .05em;
    color: var(--lp-muted);
}
.chlook-outfit-add {
    height: 28px;
    padding: 0 10px;
    border-radius: 8px;
    border: 1px dashed var(--lp-line);
    background: transparent;
    color: var(--lp-muted);
    font-family: inherit;
    font-size: 11px;
    cursor: pointer;
}
.chlook-outfit-add:hover { border-color: rgba(212,106,147,.6); color: var(--lp-fg); }
.chlook-outfit-list {
    display: flex;
    gap: 7px;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: none;
}
.chlook-outfit-list::-webkit-scrollbar { display: none; }
.chlook-outfit-card {
    flex: none;
    display: flex;
    align-items: center;
    gap: 6px;
    max-width: 150px;
    height: 32px;
    padding: 0 9px;
    border-radius: 9px;
    border: 1px solid var(--lp-line);
    background: transparent;
    color: var(--lp-muted);
    font-family: inherit;
    font-size: 11px;
    cursor: pointer;
}
.chlook-outfit-card i {
    width: 14px; height: 14px; flex: none;
    border-radius: 50%;
    box-shadow: 0 0 0 1px rgba(255,255,255,.22) inset;
}
.chlook-outfit-card span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chlook-outfit-card b {
    font-weight: 500;
    font-size: 9px;
    padding: 1px 5px;
    border-radius: 99px;
    background: var(--lp-accent-soft);
    color: var(--lp-accent);
}
.chlook-outfit-card.on {
    border-color: rgba(212,106,147,.62);
    background: var(--lp-accent-soft);
    color: var(--lp-fg);
}
.chlook-outfit-actions {
    display: flex;
    justify-content: flex-end;
    gap: 6px;
    margin-top: 7px;
}
.chlook-outfit-actions.hide { display: none; }
.chlook-outfit-actions button {
    height: 26px;
    padding: 0 9px;
    border-radius: 8px;
    border: 1px solid var(--lp-line);
    background: transparent;
    color: var(--lp-muted);
    font-family: inherit;
    font-size: 11px;
    cursor: pointer;
}
.chlook-outfit-actions button:hover { color: var(--lp-fg); border-color: rgba(212,106,147,.5); }
.chlook-outfit-actions button:disabled { opacity: .35; cursor: default; }
html[data-mode="day"] .chlook-outfit-card i { box-shadow: 0 0 0 1px rgba(48,30,40,.18) inset; }

.chlook-hint {
    margin-top: 12px;
    text-align: center;
    font-size: 10px;
    letter-spacing: .06em;
    color: var(--lp-muted);
    opacity: .65;
}

/* 白天 */
html[data-mode="day"] .chlook-panel {
    --lp-bg: rgba(255,251,247,.985);
    --lp-fg: #40303A;
    --lp-muted: #7E6771;
    --lp-line: rgba(48,30,40,.13);
    --lp-soft: rgba(48,30,40,.045);
    --lp-soft2: rgba(48,30,40,.075);
    --lp-accent: #B14E77;
    --lp-accent-soft: rgba(177,78,119,.13);
    --lp-stage: rgba(48,30,40,.05);
    background: rgba(60,45,52,.30);
}
html[data-mode="day"] .chlook-panel .chlook-card {
    border-color: rgba(48,30,40,.12);
    box-shadow: 0 26px 70px rgba(80,50,62,.22);
}
html[data-mode="day"] .chlook-panel .chlook-seg.on,
html[data-mode="day"] .chlook-panel .chlook-name em { color: #8C3A60; }
html[data-mode="day"] .chlook-panel .chlook-file { border-color: rgba(48,30,40,.22); }
html[data-mode="day"] .chlook-panel .chlook-swatch i { box-shadow: 0 0 0 1px rgba(48,30,40,.18) inset; }

@media (max-width: 560px) {
    .chlook-panel { padding: 0; align-items: flex-end; }
    .chlook-card {
        width: 100%;
        max-height: calc(100dvh - 24px);
        border-radius: 20px 20px 0 0;
    }
    .chlook-body { padding: 10px 12px 18px; }
    .chlook-editor { grid-template-columns: 1fr; }
    .chlook-stage { height: 224px; }
    .chlook-head { padding: 12px 14px 10px; }
}

/* 无 2D 立绘时的黑影占位（不再是白卡） */
.standee:not(.standee-has-img) {
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
}
.standee-silhouette {
    position: absolute;
    left: 50%;
    bottom: 0;
    width: 34px;
    height: 76px;
    transform: translateX(-50%);
    border-radius: 46% 46% 30% 30%;
    background: linear-gradient(180deg, rgba(35,25,31,.62), rgba(35,25,31,.38));
    filter: blur(.2px);
    pointer-events: none;
}
.standee-silhouette::before {
    content: "";
    position: absolute;
    left: 50%;
    top: -13px;
    width: 24px;
    height: 24px;
    transform: translateX(-50%);
    border-radius: 50%;
    background: rgba(35,25,31,.62);
}
html[data-mode="day"] .standee-silhouette,
html[data-mode="day"] .standee-silhouette::before {
    background: linear-gradient(180deg, rgba(70,52,60,.42), rgba(70,52,60,.24));
}
/* 交互临时记录：灰字，不自动展开文本框 */
.scene-temp-line {
    color: rgba(246,240,244,.46) !important;
    font-size: 12px;
    line-height: 1.7;
    padding: 2px 0;
}
html[data-mode="day"] .scene-temp-line { color: rgba(70,52,60,.48) !important; }
/* 文本框内的角色请求：不弹窗，可直接接受/拒绝，也可以打字回应 */
.scene-request-inline {
    margin: 8px 0 4px;
    padding: 10px 12px;
    border-radius: 12px;
    border: 1px solid rgba(212,106,147,.32);
    background: rgba(212,106,147,.08);
}
.scene-request-text {
    font-size: 12px;
    line-height: 1.6;
    color: inherit;
}
.scene-request-text span {
    display: block;
    margin-top: 2px;
    font-size: 10px;
    opacity: .55;
}
.scene-request-actions {
    display: flex;
    gap: 8px;
    margin-top: 8px;
}
.scene-request-actions button {
    padding: 5px 12px;
    border-radius: 8px;
    border: 1px solid rgba(212,106,147,.35);
    background: transparent;
    color: inherit;
    font-family: inherit;
    font-size: 11px;
    cursor: pointer;
}
.scene-request-actions button[data-req="yes"] {
    background: #D46A93;
    border-color: #D46A93;
    color: #fff;
}
/* 地点动作菜单：白天浅色，避免黑夜面板 */
.item-popup-menu.day {
    background: rgba(255,250,245,.98) !important;
    border-color: rgba(36,26,34,.16) !important;
    box-shadow: 0 14px 34px rgba(70,40,50,.18) !important;
    backdrop-filter: blur(16px) !important;
    -webkit-backdrop-filter: blur(16px) !important;
}
.item-popup-menu.day .item-popup-item {
    color: #46343c !important;
}
.item-popup-menu.day .item-popup-item:hover {
    background: rgba(212,106,147,.10) !important;
}
/* 日间地点页：顶栏/输入栏强制跟随浅色主题 */
html[data-mode="day"] .location-topbar {
    background: #FBF4E6 !important;
    color: #4A3A34 !important;
}
html[data-mode="day"] .location-title { color: #3A2C27 !important; }
html[data-mode="day"] .scene-input-bar {
    background: #FBF4E6 !important;
    border-top-color: rgba(120,90,70,.12) !important;
}
html[data-mode="day"] .scene-input-bar .location-input {
    background: #FFFFFF !important;
    color: #4A3A34 !important;
    border-color: rgba(36,26,34,.12) !important;
}
html[data-mode="day"] .scene-input-bar .location-input::placeholder { color: rgba(90,70,60,.45) !important; }
html[data-mode="day"] .scene-text-area .vn-content { color: #4A3A34 !important; }html[data-mode="day"] .location-icon-btn.loc-more-btn {
    color: #3A2C27 !important;
    background: rgba(255,255,255,.72) !important;
    border-color: rgba(120,90,70,.16) !important;
}
html[data-mode="day"] .scene-text-area .vn-content,
html[data-mode="day"] .scene-temp-line { color: #4A3A34 !important; }