/* Cult of Igor — black obsidian / antique gold game UI. No raster icons. */
:root{--cult-gold:#f4c75d;--cult-soft:#fbe5a7;--cult-line:#8a6935;--cult-ink:#10100f}
.cult-icon-library{position:absolute!important;width:0!important;height:0!important;overflow:hidden!important;pointer-events:none}
.icon{width:22px;height:22px;display:inline-block;vertical-align:middle;flex-shrink:0;color:var(--cult-gold)}
.game .score,.game .online,.game .menu-button,.game .cult-hud-button{background:linear-gradient(140deg,#27211de8,#100e10e8);border:1px solid #c69a4f7d;box-shadow:0 4px 16px #0007,inset 0 1px #e5b66321;color:#ffe394}
.game .score{display:flex;align-items:center;gap:5px;font-size:11px}
.score>.icon{width:17px;height:17px}
.game .score b{font-size:20px;font-variant-numeric:tabular-nums}
.game .online{display:flex;align-items:center;gap:5px}
.game .menu-button,.game .cult-hud-button{z-index:7;top:calc(env(safe-area-inset-top) + 12px);width:42px;height:42px;border-radius:13px;display:grid;place-items:center;position:absolute;pointer-events:auto;padding:0}
.game .menu-button{right:12px}
.game .inventory-button{right:62px}
.game .quests-button{right:112px}
.game .voice-button{right:162px;height:42px}
.cult-hud-button .icon{width:21px;height:21px}
.game .decree{z-index:3;display:flex;align-items:center;gap:8px;text-align:left;min-height:65px;max-width:350px;width:calc(100% - 50px);top:calc(env(safe-area-inset-top) + 66px);padding:9px 11px;background:linear-gradient(145deg,#251e1be8,#0d0d10ed);border:1px solid #e2ac5d8e;box-shadow:0 6px 20px #0008;border-radius:14px}
.decree-seal{width:39px;height:41px;display:grid;place-items:center;border-radius:11px;background:linear-gradient(145deg,#6e4f1d,#32210f);flex-shrink:0}
.decree-seal .icon{width:25px;height:25px}
.decree-main{flex:1;min-width:0}
.decree-topline{color:#f6c764;letter-spacing:.055em;font-weight:900;font-size:12px;display:flex;justify-content:space-between}
#ritual-count{font-variant-numeric:tabular-nums;color:#ead9b3;font-size:10px}
.game .decree strong{font-weight:500;font-size:11px;color:#fff3d8;line-height:1.4;display:block;margin-top:2px}
.game .decree-progress{margin-top:6px;background:#544536;height:5px;border-radius:8px;overflow:hidden}
.game .decree-progress i,.cult-progress i{background:linear-gradient(90deg,#ad6f1d,#ffe489);height:100%;display:block;border-radius:inherit}
.game .voice.cult-toast{top:auto;bottom:calc(env(safe-area-inset-bottom) + 152px);left:50%;transform:translate(-50%,10px);width:min(340px,90vw);max-width:340px;display:flex;align-items:center;gap:10px;box-shadow:0 7px 35px #0009;text-align:left;border:1px solid #e8bc667d;background:linear-gradient(140deg,#33221bef,#0c0c0fec);padding:12px 14px;border-radius:15px;pointer-events:none}
.voice.cult-toast.show{transform:translate(-50%,0)}
.toast-mark{width:37px;height:37px;display:grid;place-items:center;background:#614321;border-radius:10px}.toast-mark .icon{width:24px;height:24px}
.toast-copy{display:grid;gap:3px}.toast-copy small{font-size:9px;color:#f2ba53;font-weight:800;letter-spacing:.1em}.toast-copy strong{font-size:12px;color:#fff0d3;font-weight:500}
.game .action{background:radial-gradient(circle at 35% 22%,#38250e,#090a0c 70%);border:2px solid #e7b650;color:#ffe095;box-shadow:inset 0 0 16px #d69d342f,0 0 0 4px #0006,0 3px 18px #000a}
.action-glyph{height:30px;display:grid;place-items:center}.action-glyph .icon{width:27px;height:27px}
.interact-button .icon{width:17px;height:17px;margin-right:5px}
.game .joystick-zone .stick-base{background:radial-gradient(circle,#24201880,#101113a8);border:1px solid #dbad61aa}
.game .joystick-zone .stick-knob{background:radial-gradient(circle at 35% 25%,#ffe09a,#b78830 65%,#725021);border:1px solid #ffeab4}
.game .panel.cult-panel{z-index:40;position:absolute;inset:0 0 0 auto;width:min(100%,460px);max-width:none;height:100%;display:flex;flex-direction:column;gap:0;padding:0;background:linear-gradient(160deg,#211912f8 0,#0c0d0ffb 25%,#0b0b0dfc 100%);border-left:1px solid #bc9251;box-shadow:-15px 0 55px #000b;overflow:hidden;overscroll-behavior:contain;user-select:text;touch-action:pan-y}
.cult-panel-header{display:flex;align-items:center;gap:12px;flex-shrink:0;padding:calc(env(safe-area-inset-top) + 16px) 18px 15px;border-bottom:1px solid #a882493d}
.cult-panel-header div{flex:1;min-width:0}.cult-panel-header small{display:block;font-size:10px;color:#dfab54;letter-spacing:.18em;font-weight:800;margin-bottom:6px}
.cult-panel-header h2{font-size:20px;letter-spacing:.03em;color:#f4ca6c;margin:0}
.cult-panel-header button,.cult-item-dialog .cult-close{border-radius:12px;border:1px solid #a4824c85;background:#282119;color:#ffe1a2;width:42px;height:42px;min-height:42px;display:grid;place-items:center;flex-shrink:0}
.cult-panel-header .cult-panel-back .icon{transform:rotate(0deg)}
.cult-close .icon{width:19px;height:19px}
.cult-panel-scroll{padding:19px 18px 24px;overflow-y:auto;flex:1;min-height:0;overscroll-behavior:contain}
.cult-view{display:flex;flex-direction:column;gap:13px}
.cult-profile-card{border:1px solid #937145a3;border-radius:15px;background:linear-gradient(145deg,#31271bdc,#181515);padding:14px;display:flex;align-items:center;gap:14px}
.profile-avatar{width:57px;height:57px;border-radius:14px;background:radial-gradient(circle at 50% 20%,#b88728,#503514);display:grid;place-items:center;flex-shrink:0}
.profile-avatar .icon{width:34px;height:34px;color:#ffe299}
.profile-content{display:flex;flex-direction:column;gap:4px;min-width:0}
.profile-content small{font-size:10px;letter-spacing:.09em;color:#e9b55e}
.profile-content strong{font-size:17px;color:#ffe19b}
.profile-content span{font-size:12px;color:#d8c2a2}
.profile-content b{color:#e6bd66}
.cult-stats-row{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.cult-stats-row>div{background:#191715;border:1px solid #725b3e;border-radius:12px;padding:11px;display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.cult-stats-row .icon{width:22px;height:22px}.cult-stats-row span{color:#cdbd9e;font-size:10px;letter-spacing:.04em}.cult-stats-row b{margin-left:auto;color:#ffe08e;font-size:15px}
.cult-menu-links{display:flex;flex-direction:column;gap:9px}
.cult-menu-links a{text-decoration:none}
.cult-menu-links :is(button,a){border:1px solid #8d703e;border-radius:13px;background:linear-gradient(100deg,#27221b,#161616);color:#f7e6c0;padding:12px;display:flex;align-items:center;gap:12px;text-align:left}
.cult-menu-links :is(button,a)>.icon:first-child{height:25px;width:25px}
.cult-menu-links :is(button,a) span{flex:1;display:flex;flex-direction:column;gap:3px}
.cult-menu-links :is(button,a) strong{font-size:14px;font-weight:650}.cult-menu-links :is(button,a) small{font-size:11px;color:#b8a991}
.cult-menu-links .nav-arrow{transform:rotate(180deg);width:18px;height:18px}
.cult-menu-links :is(button,a):active,.cult-panel-nav button:active,.cult-item-card:not(:disabled):active{background:#5f4724}
.cult-online{border-top:1px solid #5e4b2d;padding-top:13px}
.cult-online h3,.cult-subhead{color:#ecc16d;font-size:11px;letter-spacing:.08em;margin:4px 0 10px;display:flex;align-items:center;gap:7px}
.cult-online ul{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:7px;max-height:none;overflow:visible}
.cult-online li{color:#e7dccd;border-bottom:1px solid #66553944;padding:5px 0;font-size:13px;margin:0}
.cult-panel-nav{display:grid;grid-template-columns:repeat(4,1fr);gap:1px;background:#181513;border-top:1px solid #7e6239;flex-shrink:0;padding:7px 5px calc(env(safe-area-inset-bottom) + 7px)}
.cult-panel-nav button{display:flex;flex-direction:column;align-items:center;gap:4px;background:transparent;color:#bba881;border:0;border-radius:9px;padding:9px 3px;font-size:10px}
.cult-panel-nav button.selected{background:#514024;color:#ffdc8b}.cult-panel-nav button.selected .icon{color:#ffda78}
.cult-panel-nav .icon{width:23px;height:23px}
.cult-help{font-size:12px;color:#cbbca4;margin:0;line-height:1.55}
.inventory-balance{display:flex;gap:13px;align-items:center;padding:16px 13px;border:1px solid #c89e58;border-radius:14px;background:linear-gradient(120deg,#473016,#211a13)}
.balance-icon{width:53px;height:53px;border-radius:11px;display:grid;place-items:center;background:#8b621c66}.balance-icon .icon{width:33px;height:33px}
.inventory-balance>span:nth-child(2){display:grid;gap:5px;flex:1}.inventory-balance small{color:#e4c891;font-size:10px;letter-spacing:.08em}
.inventory-balance strong{color:#ffe39a;font-size:27px;font-variant-numeric:tabular-nums}.balance-label{font-size:9px;color:#dfba75}
.cult-tabs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));padding:3px;border:1px solid #645033;border-radius:13px;background:#171616;gap:3px}
.cult-tabs button{border:0;background:transparent;color:#cbbca1;padding:12px 4px;border-radius:10px;font-size:12px;font-weight:700}
.cult-tabs button.selected{background:linear-gradient(#ffe9a2,#dda33d);color:#281a0b}
.inventory-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:11px}
.cult-item-card{min-height:146px;min-width:0;border:1px solid #997341;border-radius:13px;background:radial-gradient(circle at 50% 28%,#503817,#151414 75%);display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;padding:10px;color:#f7d791}
.cult-item-card .cult-item-art{height:62px;display:grid;place-items:center}
.cult-item-card .cult-item-art .icon{width:58px;height:58px;stroke-width:1.3;filter:drop-shadow(0 3px 10px #bc812f66)}
.cult-item-card b{font-size:12px;font-weight:650;text-align:center}.cult-item-card small{font-size:12px;color:#ffdb85}
.cult-item-card.is-locked{border-color:#3c3933;color:#736957;background:#151514;opacity:.64}
.cult-item-card.is-locked .icon{color:#68645c}.cult-item-card.is-locked small{color:#908474}
.cult-inventory-hint{font-size:12px;line-height:1.5;color:#cebb9a;background:#2b2115;border:1px solid #725b3c;border-radius:10px;padding:12px;margin:0}
.cult-quests-list{display:flex;flex-direction:column;gap:12px}
.cult-quest-card{border:1px solid #8c6c38;border-radius:13px;padding:12px;background:linear-gradient(120deg,#30251b,#141315)}
.cult-quest-card.completed{border-color:#ddae56}
.cult-quest-top{display:flex;align-items:center;gap:9px}.cult-quest-icon{width:40px;height:40px;border-radius:9px;background:#73511a;display:grid;place-items:center}
.cult-quest-copy{flex:1;min-width:0;display:flex;flex-direction:column;gap:3px}
.cult-quest-copy b{font-size:13px;color:#f3dfb8}.cult-quest-copy small{font-size:11px;line-height:1.4;color:#c6b79c}
.cult-quest-count{color:#f6ca65;font-size:11px;white-space:nowrap}
.cult-progress{background:#4e402c;border-radius:8px;height:8px;overflow:hidden;margin-top:10px}
.cult-quest-reward{display:block;margin-top:9px;color:#dfc69b;font-size:11px}
.cult-setting{background:#201c18;border:1px solid #8f6c3e;color:#ffe4a5;border-radius:12px;min-height:60px;display:flex;gap:11px;align-items:center;text-align:left;padding:13px}
.cult-setting .icon{width:25px;height:25px}.cult-setting .setting-title{display:block;font-size:13px;color:#fff1cc}.cult-setting .setting-title b{color:#f4c86a}
.cult-setting .setting-title small{display:block;color:#afa08b;font-size:11px;margin-top:5px}
.cult-settings-footnote{font-size:11px;color:#bcb099;line-height:1.6;padding:13px;background:#181715;border-radius:10px}
.game .cult-item-dialog{margin:auto;position:fixed;max-width:min(90vw,390px);width:100%;padding:23px 20px 20px;color:#ffe6ad;background:linear-gradient(145deg,#33251a,#101012);border:1px solid #c39851;border-radius:21px;box-shadow:0 25px 80px #000d;text-align:center}
.cult-item-dialog::backdrop{background:#000b;backdrop-filter:blur(4px)}
.cult-item-dialog .cult-close{position:absolute;right:10px;top:10px;width:35px;height:35px;min-height:35px}
.item-dialog-art{margin:20px auto 10px;width:96px;height:90px;display:grid;place-items:center;background:radial-gradient(circle,#9d7026,#322315 62%,transparent 72%)}
.item-dialog-art .icon{width:75px;height:75px}
.item-dialog-tag{letter-spacing:.12em;color:#efb95c;font-size:11px}
.cult-item-dialog h2{font-size:22px;margin:10px 0;color:#ffe6a5}
.cult-item-dialog p{font-size:13px;line-height:1.6;color:#d6c2a2}
#item-dialog-count{font-size:14px;display:block;margin:14px}
.cult-dialog-done{width:100%;padding:13px;background:linear-gradient(#ffe89b,#d7a43e);border:0;color:#201509;font-weight:800;border-radius:12px}
@media(max-width:600px){
 .game .panel.cult-panel{width:100%;border-left:0}
 .game .voice-button{right:160px}
 .game .decree{top:calc(env(safe-area-inset-top) + 62px);max-width:calc(100% - 38px)}
}
@media(max-width:370px){
 .game .score span{display:none}
 .game .voice-button{right:150px;width:37px}
 .game .quests-button{right:106px;width:37px}
 .game .inventory-button{right:62px;width:37px}
 .game .menu-button{width:37px}
 .game .score b{font-size:17px}
}
@media(max-height:620px){
 .cult-panel-header{padding-top:calc(env(safe-area-inset-top) + 6px);padding-bottom:8px}
 .cult-panel-scroll{padding-top:10px}
 .game .decree{top:calc(env(safe-area-inset-top) + 52px)}
 .game .voice.cult-toast{bottom:calc(env(safe-area-inset-bottom) + 105px)}
}

/* A portrait screen cannot fit 4 quick buttons beside two score pills. */
@media(max-width:600px){
 .game .inventory-button,.game .quests-button,.game .voice-button{top:calc(env(safe-area-inset-top) + 63px)}
 .game .decree{top:calc(env(safe-area-inset-top) + 114px);width:calc(100% - 26px);max-width:350px}
 .game .top-left{max-width:calc(100% - 63px)}
 .game .online{white-space:nowrap}
}
@media(max-width:370px){
 .game .inventory-button,.game .quests-button,.game .voice-button{top:calc(env(safe-area-inset-top) + 60px)}
 .game .decree{top:calc(env(safe-area-inset-top) + 110px)}
}
@media(max-width:600px) and (max-height:620px){
 .game .decree{top:calc(env(safe-area-inset-top) + 106px)}
}

/* The throne's messages need a recognizable visual voice, not a generic alert. */
.game .cult-toast.igor-speaking{border-color:#ffce65;box-shadow:0 0 0 1px #d5a44c44,0 7px 34px #000b,0 0 26px #ffca5430;background:linear-gradient(140deg,#493014f5,#151112f7)}
.game .cult-toast.igor-speaking .toast-mark{background:linear-gradient(155deg,#8a5c21,#30200f);box-shadow:inset 0 1px #ffdf8e77}
.game .cult-toast.igor-speaking .toast-copy small{color:#ffda88;letter-spacing:.13em}
.game .cult-toast.igor-speaking .toast-copy strong{color:#fff0c3;line-height:1.45}

/* Gold bonus appears independently so an epic Igor announcement remains readable. */
.game .synchrony-bonus{
  position:absolute;z-index:8;left:50%;top:calc(env(safe-area-inset-top) + 194px);
  transform:translate(-50%,-12px) scale(.96);opacity:0;transition:opacity .24s,transform .24s;
  width:max-content;max-width:calc(100vw - 28px);padding:12px 18px;pointer-events:none;
  border:1px solid #fff0b9;border-radius:13px;text-align:center;
  color:#fff5d1;font-size:13px;line-height:1.4;font-weight:800;letter-spacing:.025em;
  background:linear-gradient(125deg,#7e5019ed,#241a11f4 55%,#765019ed);
  box-shadow:0 5px 26px #000b,0 0 24px #f5c34d65,inset 0 0 12px #f6c35f55;
}
.game .synchrony-bonus.show{opacity:1;transform:translate(-50%,0) scale(1)}
@media(min-width:601px){.game .synchrony-bonus{top:calc(env(safe-area-inset-top) + 112px)}}
@media(max-height:530px){.game .synchrony-bonus{top:calc(env(safe-area-inset-top) + 58px)}}

/* Private relationship-level celebration; separate from global Igor speech & bonus. */
.game .mood-change{
  position:absolute;z-index:9;left:50%;bottom:calc(env(safe-area-inset-bottom) + 240px);
  transform:translate(-50%,12px) scale(.96);opacity:0;
  width:max-content;max-width:min(370px,calc(100vw - 28px));
  pointer-events:none;display:grid;gap:4px;padding:12px 18px;
  text-align:center;border-radius:15px;border:1px solid #e3b65d;
  background:linear-gradient(135deg,#402d1bee,#1b1717f6 70%,#534024ee);
  color:#ffefca;box-shadow:0 8px 29px #0009,0 0 20px #dca34544;
  transition:opacity .24s ease,transform .24s ease;
}
.game .mood-change.show{opacity:1;transform:translate(-50%,0) scale(1)}
.game .mood-change small{font-size:10px;font-weight:850;letter-spacing:.1em;color:#f5c66d}
.game .mood-change strong{font-size:15px;line-height:1.3;color:#ffe6a5}
.game .mood-change span{font-size:12px;line-height:1.4;color:#e6d4b9}
.game .mood-change.worsened{
  border-color:#c06c57;background:linear-gradient(135deg,#492723f0,#201619f8 70%,#432b26f0);
  box-shadow:0 8px 29px #000a,0 0 20px #d5654c33
}
.game .mood-change.worsened small{color:#ff9c86}
.game .mood-change.worsened strong{color:#ffc9b3}
@media(max-height:600px){.game .mood-change{bottom:calc(env(safe-area-inset-bottom) + 168px)}}
@media(prefers-reduced-motion:reduce){.game .mood-change{transition:none}}

/* Personal gift count sits inside the existing top-left faith card. */
.game .score{flex-direction:column;align-items:flex-start;justify-content:center;gap:1px;padding:6px 10px}
.game .score .score-faith{display:flex;align-items:center;gap:5px;line-height:1.2}
.game .score .score-faith .icon{width:17px;height:17px}
.game .score .score-gifts{display:flex;align-items:baseline;gap:5px;margin-left:22px;white-space:nowrap;line-height:1.2}
.game .score .score-gifts b{font-size:12px;color:#f6d388;font-variant-numeric:tabular-nums}
.game .score .score-gifts span{font-size:9px;color:#d7c29e;letter-spacing:.06em}
.game .top-left{align-items:flex-start}
/* Relationship heading and its personal status must always be on distinct lines. */
.profile-content .igor-relationship{display:flex;flex-direction:column;align-items:flex-start;gap:4px}
.profile-content .igor-relationship b{display:block;line-height:1.4;overflow-wrap:anywhere}

/* Offline followers are persistent server profiles, not cached client nicknames. */
.cult-offline{border-top:1px solid #6e5330;padding-top:12px;margin-top:4px}
.cult-offline .cult-subhead{margin:0 0 10px}
.cult-offline .cult-subhead .icon{width:17px;height:17px;flex-shrink:0}
.cult-offline .cult-subhead span{margin-left:auto;color:#d3bd8c}
.cult-offline ul{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:8px}
.cult-offline li{min-width:0;padding:10px 12px;border:1px solid #655034;border-radius:10px;background:linear-gradient(105deg,#25201b,#171516)}
.cult-offline-player{display:flex;flex-wrap:wrap;gap:4px 10px;justify-content:space-between;align-items:baseline}
.cult-offline-name{color:#f2ddad;font-size:13px;overflow-wrap:anywhere}
.cult-offline-stats{color:#d7c39d;font-size:12px;font-variant-numeric:tabular-nums}
.cult-offline .cult-offline-empty{font-size:12px;color:#bcb099;font-style:italic}

.cult-settings-footnote a{color:#e8c276;text-decoration:underline;text-underline-offset:2px}
