.local-chip{position:fixed;right:12px;top:8px;z-index:1500;border:1px solid #f1d49e;background:#2c241de8;color:#fbe5b7;padding:6px 10px;border-radius:18px;font:600 11px system-ui;cursor:pointer;box-shadow:0 2px 10px #0003}.local-dialog{max-width:520px;width:calc(100% - 32px);max-height:85vh;overflow:auto;border:1px solid #d0b685;border-radius:22px;padding:24px;background:#fbf5e8;color:#443024;font:14px/1.6 system-ui}.local-dialog::backdrop{background:#20180fb8;backdrop-filter:blur(3px)}.local-dialog h2{font:600 26px Georgia;margin:0 0 8px}.local-dialog p{margin:10px 0}.local-dialog button{margin:6px 6px 0 0;padding:10px 13px;border:1px solid #c5a66b;border-radius:10px;background:#edcf91;color:#3e2d15;cursor:pointer;font:600 13px system-ui}.local-dialog button.secondary{background:transparent}.local-dialog small{display:block;color:#71604d}.local-dialog pre{white-space:pre-wrap;word-break:break-word;max-height:130px;overflow:auto;font:11px monospace;background:#efe5d3;padding:10px;border-radius:8px}.local-status{padding:8px 10px;background:#e8eddf;border-radius:9px}@media(max-width:600px){.local-chip{font-size:10px;top:4px;right:4px;padding:5px 8px}}
.local-calendar{display:block;max-width:260px;font-size:11px;line-height:1.5;color:#fff1d2;text-shadow:0 1px 3px #261a16;background:#2e271bb8;border-radius:8px;padding:3px 7px}
.public-server .local-only,.public-server .local-chip{display:none!important}.free-wallet{padding:20px;text-align:center;border:1px solid #dac08b;background:#fff9e9;border-radius:18px}.free-wallet small{display:block;color:#766149;line-height:1.6}.free-wallet p{line-height:1.6}.recovery-code{white-space:pre-wrap;overflow-wrap:anywhere;user-select:all;font:16px/1.6 monospace}.acc-form label{min-width:0}.acc-form input{min-width:0;max-width:100%}
.chore-btn.sweeping{display:flex;flex-direction:column;align-items:stretch;gap:4px;width:210px;max-width:100%;padding:9px 12px;border-radius:14px;background:#241d13dc;text-align:left;text-shadow:none}
.chore-btn .sweep-label{display:flex;align-items:center;justify-content:space-between;gap:10px;font-size:11px;color:#e8d9b4}.sweep-label small{font-size:10px;font-weight:400;color:#f5cc77}.chore-btn #sweepCount{font-size:15px;color:#ffe5aa;font-variant-numeric:tabular-nums}.chore-btn progress{width:100%;height:4px;accent-color:#d1ac5c;border:0;margin:2px 0 0}.chore-btn.paused{border-color:#e7a278}.sweep-summary{padding:12px;background:#eee4ce;border-radius:12px}.sweep-summary>p,.sweep-help p{font-size:12px;line-height:1.6}.sweep-error{color:#933e2d}.sweep-help{text-align:left}.sweep-help summary{cursor:pointer;font-size:12px;color:#786044;padding:6px}.chore-other{justify-content:center;gap:6px}.chore-other .btn{font-size:12px;padding:8px 10px}.modal-card:has(.sweep-help){max-height:calc(100dvh - 24px);overflow-y:auto}
.ritual-controls{display:flex;gap:6px;align-items:center;flex-wrap:wrap;padding:4px 12px}.ritual-controls span{font-size:11px;color:#7a5d3e;flex:1;min-width:110px}.ritual-controls .btn{margin:0}.chant .chant-note{margin:4px 12px}.lamp-card{padding:14px;border:1px solid #dfc89d;border-radius:16px;background:#fff8e8;margin:14px 0}.lamp-card h3{margin:0 0 8px}.lamp-card p{font-size:12px;line-height:1.6}.lamp-tiers{display:flex;flex-wrap:wrap;gap:6px}.lamp-tiers span{font-size:11px;border:1px solid #dfd7c5;border-radius:12px;padding:4px 8px;color:#82796d}.lamp-tiers .lit{color:#654214;border-color:#c5a45d;background:#f9e9ba}
@media(max-width:600px){.local-calendar{max-width:190px;font-size:10px}.chore-btn.sweeping{width:min(190px,calc(50vw - 16px));padding:7px 9px}.chore-btn #sweepCount{font-size:13px}.chore-btn .sweep-label{font-size:10px;gap:4px}.sweep-label small{font-size:9px}.ritual-controls{padding:3px 10px}.ritual-controls span{flex-basis:100%}}
@media(max-height:480px){.chore-btn.sweeping{width:185px;padding:5px 10px;gap:2px}.chore-btn .sweep-label{font-size:10px}.chore-btn #sweepCount{font-size:13px}}
@media(orientation:landscape) and (max-height:520px){.zoom-btns{left:calc(220px + var(--sl));top:calc(68px + var(--st));transform:none}}
.ritual-controls span{color:#ecd7ae}.ritual-controls .ghost{color:#ffe3aa;border-color:#957442;background:#3d2b18}

/* Compact HUD: primary practice stays on screen, secondary features in one menu. */
.camera-marker{position:fixed;z-index:1;pointer-events:none;transform:translate(-50%,calc(-100% - 12px));padding:4px 9px;border:1px solid #fff0ba;border-radius:12px;background:#ffdb7a;color:#39280f;font:700 11px system-ui;text-shadow:none;box-shadow:0 2px 8px #0008}.camera-marker::after{content:'';position:absolute;left:50%;bottom:-5px;width:8px;height:8px;background:#ffdb7a;transform:translateX(-50%) rotate(45deg);border-right:1px solid #fff0ba;border-bottom:1px solid #fff0ba}
.compact-hud #toast{width:max-content;line-height:1.5;padding:10px 16px}
.compact-hud label.setting{flex-wrap:nowrap;line-height:1.45}.compact-hud .setting-text{flex:1;min-width:0}.compact-hud .setting>.i,.compact-hud .setting input[type=checkbox]{flex-shrink:0}.compact-hud .setting select{min-width:0;max-width:65%}.compact-hud .setting:not(.vol) input[type=range]{width:100px;flex:0 1 45%}
.compact-hud .hud-top{align-items:flex-start}.compact-hud .top-right{max-width:none;flex-wrap:nowrap;align-items:center;gap:8px}.compact-hud #btnUi{width:auto;min-width:78px;height:44px;border-radius:14px;padding:0 12px;display:flex;align-items:center;gap:8px;font-size:12px;position:relative}.compact-hud #btnUi>span{font-size:20px}
.compact-hud:has(#hudMenu .badge:not(.hidden),#hudMenu .mail-badge:not(.hidden)) #btnUi::after{content:'';position:absolute;right:4px;top:2px;width:8px;height:8px;border-radius:50%;background:#e26e51;border:1px solid #ffe5aa}
.compact-hud:has(#hud:not(.hidden))>.local-chip{display:none}
.compact-hud:has(#hudMenu:not(.hidden)) #toast{visibility:hidden}
.hud-menu-veil{position:fixed;inset:0;z-index:30;border:0;background:#0d0b085c;backdrop-filter:blur(2px);cursor:default}
.hud-menu{position:fixed;right:12px;top:calc(66px + var(--st));z-index:31;width:min(370px,calc(100vw - 24px));max-height:calc(100dvh - 80px - var(--st));overflow:auto;overscroll-behavior:contain;padding:16px;border:1px solid #ab8d59;border-radius:20px;color:#f3dfb4;background:#241b12f5;box-shadow:0 10px 40px #0005;text-shadow:none}
.hud-menu>header{display:flex;align-items:center;justify-content:space-between;gap:12px}.hud-menu h3{margin:0;font-size:19px}.hud-menu h4{margin:16px 0 8px;color:#d6bc87;font-size:11px;text-transform:uppercase;letter-spacing:.07em}.hud-menu button{font:inherit;color:inherit;cursor:pointer}.hud-menu>header button{width:38px;height:38px;border-radius:12px;border:1px solid #9f845a66;background:#ffffff08;font-size:24px}
.compact-hud #hudMenu .side-menu,.hud-utilities{position:static;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));grid-template-rows:none;grid-auto-flow:row;gap:7px;direction:ltr;transform:none;max-height:none;max-width:none;overflow:visible;padding:0}
.compact-hud #hudMenu .side-menu button,.compact-hud .hud-utilities button{position:relative;width:100%;height:auto;min-height:62px;margin:0;padding:9px 5px;border:1px solid #a6874e40;border-radius:12px;background:#ffffff06;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:6px;line-height:1.25;font-size:11px;text-align:center;backdrop-filter:none}
.compact-hud #hudMenu .side-menu em,.compact-hud .hud-utilities em{display:block;font-style:normal;font-size:11px}.compact-hud #hudMenu button:hover{background:#bb93551a}.compact-hud #hudMenu .i{width:19px;height:19px}.compact-hud #hudMenu button:focus-visible,.compact-hud .hud-quick button:focus-visible{outline:2px solid #f6cb73;outline-offset:2px}
.compact-hud #hudMenu #btnShare,.compact-hud #hudMenu #btnHelp,.compact-hud #hudMenu #btnDonate{display:flex}
.camera-tools{border-top:1px solid #b3945a44;margin-top:16px;padding-top:2px}.camera-tools label{display:flex;justify-content:space-between;font-size:12px}.camera-tools small{color:#c5b18f}.camera-tools input{width:100%;accent-color:#d7b063;margin:12px 0;height:24px}.camera-tools>div{display:flex;gap:8px}.camera-tools button{flex:1;padding:10px;border:1px solid #a6874e66;border-radius:10px;background:#ffffff09;font-size:12px}.camera-tools p{font-size:11px;line-height:1.6;color:#c5b18f;margin:10px 0 0}
.hud-quick{position:fixed;right:12px;top:calc(72px + var(--st));display:flex;gap:6px}.hud-quick button{font:600 12px inherit;color:#f4d9a4;min-height:38px;padding:7px 12px;border:1px solid #b2935e88;border-radius:12px;background:#241b13bf;cursor:pointer}
.compact-hud .actions{left:50%;right:auto;bottom:calc(12px + var(--sb));transform:translateX(-50%);grid-template-columns:repeat(6,68px);gap:8px}.compact-hud .act{width:68px;height:68px;border-radius:18px}.compact-hud .ctx-wrap{right:12px;bottom:calc(94px + var(--sb));width:auto;max-width:260px}.compact-hud .pop{bottom:calc(94px + var(--sb))}
.compact-hud .wish-dock{top:calc(118px + var(--st));bottom:auto;width:260px;max-height:min(360px,calc(100dvh - 220px))}.compact-hud .wd-open{top:calc(118px + var(--st));right:12px}.compact-hud .bond-box{top:calc(122px + var(--st));bottom:auto;left:auto;right:12px;transform:none;width:160px;font-size:12px}
.compact-hud .modal-card{max-height:calc(100dvh - 24px);overflow:auto;overscroll-behavior:contain}.compact-hud .sheet-card{max-height:88dvh}.compact-hud .setting{flex-wrap:wrap;gap:8px}.compact-hud .setting select{max-width:100%}.compact-hud #toast{top:auto;bottom:calc(94px + var(--sb));max-width:min(440px,calc(100vw - 24px));font-size:12px}.compact-hud .guide{top:auto;bottom:calc(88px + var(--sb));padding:0 12px;font-size:11px}
@media(min-width:900px){.compact-hud .sheet-card{width:min(760px,calc(100vw - 48px))}.compact-hud .wallet{flex-direction:row;align-items:center}.compact-hud .zoom-btns{top:50%;left:12px;transform:translateY(-50%)}}
@media(max-width:600px){
  .compact-hud .hud-top{left:8px;right:8px;gap:6px}.compact-hud .me-chip{max-width:calc(100vw - 175px);padding:5px;gap:5px}.compact-hud .me-ava{width:28px;height:28px}.compact-hud .me-info b{font-size:12px}.compact-hud .xp{width:75px;max-width:100%}.compact-hud .me-lv{min-width:20px;height:20px;font-size:10px;padding:0 3px}.compact-hud .me-info small{font-size:10px}.compact-hud .top-right{gap:5px}.compact-hud #btnUi{min-width:68px;height:42px;padding:0 8px;gap:5px}.compact-hud .wallet span{padding:3px 7px;font-size:11px}.compact-hud .wallet{gap:3px}
  .compact-hud .actions{width:calc(100vw - 20px);max-width:470px;grid-template-columns:repeat(6,minmax(0,1fr));gap:5px;bottom:calc(10px + var(--sb))}.compact-hud .act{width:100%;height:60px;border-radius:14px}.compact-hud .act span{font-size:22px}.compact-hud .act em{font-size:10px}.compact-hud .ctx-wrap{bottom:calc(84px + var(--sb));max-width:190px}.compact-hud .ctx{height:40px;font-size:12px}.compact-hud .pop{bottom:calc(84px + var(--sb));max-width:calc(100vw - 24px)}
  .compact-hud .hud-temple{left:10px}.compact-hud .hud-quick{right:10px;gap:5px}.hud-quick button{padding:6px 8px;font-size:11px;min-height:36px}.compact-hud .bond-box{width:min(150px,calc(50vw - 20px));right:10px;padding:7px}.compact-hud .bond-info{font-size:11px}.compact-hud .bond-box .btn{font-size:11px}
  .compact-hud .sheet-card{max-height:92dvh}.compact-hud .setting{font-size:13px;padding:11px}.compact-hud .ritual-controls .btn{font-size:11px;padding:8px}.compact-hud .chant-pick button{font-size:12px;padding:7px 10px}.compact-hud section.chant{--h:clamp(100px,20vh,180px);padding-left:10px;padding-right:10px;max-height:calc(100dvh - 62px);overflow:auto}.compact-hud .chant-auto{font-size:11px}.compact-hud .mo{width:82px;height:72px}.compact-hud .chant-lines p{font-size:16px}.compact-hud .chant-note{font-size:11px}.compact-hud .ritual-controls span{font-size:10px}
}
.admin-badge{display:inline-flex;align-items:center;white-space:nowrap;vertical-align:middle;font:800 10px/1.4 system-ui,sans-serif;letter-spacing:.3px;color:#5c2f08;background:linear-gradient(125deg,#ffe6a2,#dfb34d);border:1px solid #ba8730;border-radius:7px;padding:2px 6px;margin:2px 4px 2px 0;box-shadow:0 1px 4px #5c2f0820}
.hud-utilities .admin-menu-button{color:#ffdf95;border-color:#cba14f}.admin-panel{font-size:14px;overflow-wrap:anywhere}.admin-panel h4{margin:12px 0}.admin-note{font-size:12px;color:#6c5e48;line-height:1.6}.admin-summary{font-weight:700;padding:10px 0}.admin-search,.admin-actions{display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin:10px 0}.admin-search>label:first-child{flex:1;min-width:140px}.admin-panel label{display:grid;gap:6px;font-size:13px}.admin-panel input:not([type=checkbox]),.admin-panel select,.admin-panel textarea{box-sizing:border-box;min-width:0;width:100%;font:inherit;color:inherit;padding:10px;border:1px solid #cbb98f;border-radius:10px;background:#fffaf1}.admin-panel textarea{resize:vertical}.admin-panel .admin-check{display:flex;align-items:center;gap:6px}.admin-panel .btn{min-height:40px;white-space:normal}.admin-panel .btn:disabled{opacity:.45;cursor:not-allowed}.admin-player{display:flex;align-items:center;justify-content:space-between;gap:10px;border:1px solid #d4c6aa;border-radius:12px;padding:12px;margin:8px 0}.admin-player>div{min-width:0}.admin-player small{display:block;margin-top:4px;color:#706247}.admin-form{display:grid;gap:14px}.admin-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.admin-log{border-bottom:1px solid #d4c6aa;padding:12px 0}.admin-log summary{cursor:pointer;font-weight:600}.admin-log pre{white-space:pre-wrap;overflow-wrap:anywhere;max-width:100%;font-size:12px;background:#e9dfca;padding:10px;border-radius:8px}.admin-confirm-text{white-space:pre-wrap;line-height:1.7;border:1px solid #cba14f;background:#fff6da;padding:14px;border-radius:12px}
@media(max-width:480px){.admin-grid{grid-template-columns:1fr}.admin-player{align-items:flex-start;flex-direction:column}.admin-player .admin-actions{margin:4px 0 0}.admin-search{align-items:flex-end}.admin-panel .btn{min-height:44px}}
@media(orientation:landscape) and (max-height:520px){
  .compact-hud .hud-temple{top:calc(64px + var(--st))}
  .compact-hud .actions{left:auto;right:10px;bottom:10px;transform:none;width:auto;grid-template-columns:repeat(2,52px);gap:6px}.compact-hud .act{width:52px;height:52px;border-radius:14px}.compact-hud .act em{font-size:9px}.compact-hud .ctx-wrap{right:10px;bottom:190px;width:110px}.compact-hud .ctx{font-size:11px;padding:0 8px;height:38px}.compact-hud .hud-quick{right:10px;top:64px}.compact-hud .bond-box{right:10px;top:108px;width:110px}.compact-hud .hud-menu{top:10px;max-height:calc(100dvh - 20px)}.compact-hud .zoom-btns{left:220px;top:68px;transform:none}.compact-hud .guide{display:none}
}
