/* An image-led library, scoped to its dialog so the game keeps its viewport budget. */
.moods-dialog.modal{width:min(1020px,calc(100vw - 24px));max-width:1020px;max-height:calc(100dvh - 24px);padding:28px;border-radius:22px;overflow-y:auto;scrollbar-width:thin;background:linear-gradient(140deg,#24323ded,#13212bf7);border:1px solid #cab58b99;color:#f4eee1}
.moods-dialog::before{display:none}.moods-heading{padding-right:52px}.moods-heading .modal-eyebrow{font-size:14px;letter-spacing:.07em;margin:0 0 10px;color:#d7bd8c}.moods-title{font:850 clamp(27px,3.5vw,40px)/1.08 Outfit,sans-serif;letter-spacing:-.035em;margin:0 0 10px;color:#fff4df;text-wrap:balance}.moods-intro{font-size:16px;line-height:1.5;color:#c6d2d7;margin:0 0 20px;max-width:680px}
.moods-close{position:absolute;top:14px;right:14px;width:44px;height:44px;border:1px solid #e5d2a94d;border-radius:50%;background:#16242f;color:#fff0d1;font:30px/1 Outfit,sans-serif;z-index:4;cursor:pointer}.moods-close:hover{background:#354654}
.moods-tabs{display:flex;gap:6px;border:1px solid #b5c4cf38;border-radius:13px;padding:5px;margin-bottom:20px;background:#0e1a25}.moods-tabs button{flex:1;min-height:46px;border:1px solid transparent;border-radius:9px;background:transparent;color:#b5c4cd;font:750 16px Outfit,sans-serif;cursor:pointer}.moods-tabs button[aria-selected=true]{background:#3b4c58;color:#fff2d8;border-color:#d3b68055;box-shadow:0 2px 0 #0b1520}
.moods-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px}.mood-card{display:flex;flex-direction:column;align-items:stretch;min-width:0;padding:0;overflow:hidden;border:1px solid #9caeb650;border-radius:15px;background:#14232e;color:#f7f0e1;text-align:left;cursor:pointer;white-space:normal!important;box-shadow:0 4px 14px #0002;transition:transform .18s,border-color .18s,box-shadow .18s}.mood-card:hover{transform:translateY(-3px);border-color:#d8c092;box-shadow:0 8px 18px #0003}.mood-card[aria-pressed=true]{border:2px solid #e2c18a;box-shadow:0 0 0 2px #e2c18a22}
.mood-picture{display:block;position:relative;aspect-ratio:16/10;overflow:hidden;background:#293c46}.mood-picture img{display:block;width:100%;height:100%;object-fit:cover}.mood-selection{position:absolute;bottom:8px;left:8px;padding:5px 8px;border-radius:20px;background:#e0bf85;color:#24303a;font-size:14px;font-weight:800;line-height:1;opacity:0}.mood-card[aria-pressed=true] .mood-selection{opacity:1}.mood-description{display:flex;flex-direction:column;gap:7px;padding:13px;flex:1}.mood-description strong{display:block;font:800 20px/1.15 Outfit,sans-serif;letter-spacing:-.02em;text-wrap:balance}.mood-tag{display:block;color:#d9c4a0;font-size:14px;line-height:1.35}.mood-copy{display:block;color:#b9c8ce;font-size:14px;line-height:1.45}
.deck-follow{display:flex;align-items:center;justify-content:space-between;gap:15px;width:100%;min-height:70px;margin-bottom:13px;padding:13px 16px;border:1px solid #a8bac44d;border-radius:13px;background:#14232e;color:#e5eef0;text-align:left;white-space:normal!important;cursor:pointer}.deck-follow>span:first-child{display:flex;flex-direction:column;gap:6px}.deck-follow strong{font-size:17px;line-height:1.2}.deck-follow span span{font-size:14px;line-height:1.4;color:#b9ccd4}.deck-follow-mark{display:grid;place-items:center;width:28px;height:28px;flex:0 0 28px;border-radius:50%;border:1px solid #9dadb7;color:transparent;font-weight:850}.deck-follow[aria-pressed=true]{border-color:#dfbd7d;background:#243d45}.deck-follow[aria-pressed=true] .deck-follow-mark{background:#dfbd7d;color:#22323b;border-color:#dfbd7d}.deck-current{font-size:14px;line-height:1.5;color:#c5d5dc;margin:0 0 16px}.deck-preview-faces{--preview-card:clamp(58px,7vw,78px);display:flex;align-items:center;justify-content:center;height:153px;padding:15px 0;background:radial-gradient(ellipse at 50% 30%,#5b6659,#233740);overflow:hidden;pointer-events:none}.deck-preview-faces .playing-card.rogue-card{width:var(--preview-card);height:calc(var(--preview-card)*1.436);transform:rotate(-7deg);flex-shrink:0}.deck-preview-faces .playing-card.rogue-card+.playing-card.rogue-card{margin-left:-17px;transform:rotate(0deg);z-index:2}.deck-preview-faces .playing-card.rogue-card:nth-child(3){transform:rotate(7deg);z-index:1}.deck-preview-faces .rogue-index{width:17px;left:4px;top:5px}.deck-preview-faces .rogue-index-bottom{left:auto;top:auto;right:4px;bottom:5px}.deck-preview-faces .rogue-index b{font-size:18px}.deck-preview-faces .rogue-index .rogue-suit{width:12px;height:12px}.deck-preview-faces .rogue-edition{font-size:4px}.deck-preview-faces .rogue-maker{font-size:3.5px}.mood-selection-text{display:block;margin-top:auto;font-size:14px;line-height:1.4;color:#aac1ca}.deck-choice[aria-pressed=true] .mood-selection-text{color:#f0d5a2;font-weight:750}
.moods-dialog button:focus-visible{outline:3px solid #f4dba5;outline-offset:3px}.moods-dialog .mood-card:focus-visible{outline-offset:-5px}
body[data-theme=club]{--table-felt-top:#286e60;--table-felt-bottom:#123f38;--table-wood:#5c452b;--table-trim:#c5a56b}body[data-theme=saloon]{--table-felt-top:#4d684b;--table-felt-bottom:#293f2e;--table-wood:#6c4930;--table-trim:#cfa36d}body[data-theme=penthouse]{--table-felt-top:#3e5869;--table-felt-bottom:#233644;--table-wood:#353b40;--table-trim:#baaa88}body[data-theme=cosmic]{--table-felt-top:#54668f;--table-felt-bottom:#303d63;--table-wood:#4b5976;--table-trim:#c4d6f0}
@media(max-width:900px){.moods-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.moods-dialog.modal{padding:24px}.mood-description strong{font-size:19px}.deck-preview-faces{height:140px}}
@media(max-width:600px){.moods-dialog.modal{padding:20px 16px;max-height:calc(100dvh - 20px);border-radius:18px}.moods-heading{padding-right:48px}.moods-title{font-size:29px;line-height:1.1}.moods-intro{font-size:15px;margin-bottom:16px}.moods-heading .modal-eyebrow{font-size:14px}.moods-close{top:11px;right:10px}.moods-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:11px}.moods-tabs{margin-bottom:15px}.moods-tabs button{font-size:15px;min-height:44px}.mood-description{padding:11px;gap:7px}.mood-description strong{font-size:19px;line-height:1.15;min-height:43px}.mood-picture{aspect-ratio:4/3}.mood-copy{display:none}.mood-tag{font-size:14px;line-height:1.35}.mood-selection{font-size:14px;left:6px;bottom:6px;padding:5px 7px}.deck-preview-faces{height:124px}.deck-follow{padding:12px;gap:10px}.deck-follow strong{font-size:16px}.deck-follow span span{font-size:14px}.deck-current{font-size:14px}.mood-selection-text{font-size:14px}}
@media(max-width:349px){.moods-grid{grid-template-columns:1fr}.mood-picture{aspect-ratio:16/9}.mood-description strong{min-height:0}.mood-copy{display:block}.deck-preview-faces{--preview-card:76px;height:151px}.moods-title{font-size:27px}}
@media(prefers-reduced-motion:reduce){.mood-card{transition:none}.mood-card:hover{transform:none}}

/* The extended library uses real scenes and complete, independent palettes. */
body[data-theme=arcade]{--gold:#eed287;--gold-light:#fff0bd;--gold-dim:#b59b62;--ink:#15192d;--panel:#252c47;--panel-soft:#35405c;--text:#f9f4ea;--muted:#c4c7d9;--line:#d0d8f024;--ambient-color:#b1d8eb;--ambient-rgb:139,172,204;--avatar-edge:#bec7e0;--menu-surface:#252d45;--menu-field:#141d33;--menu-border:#9cadd570;--table-felt-top:#4b547b;--table-felt-bottom:#293650;--table-wood:#44415c;--table-trim:#b9cdea}
body[data-theme=haunted]{--gold:#c3d4ad;--gold-light:#e5ebcd;--gold-dim:#8e9f78;--ink:#141e1b;--panel:#24322a;--panel-soft:#34463a;--text:#f4f0df;--muted:#bdc8b8;--line:#d7dfc421;--ambient-color:#a8c9aa;--ambient-rgb:127,162,132;--avatar-edge:#acbcac;--menu-surface:#243229;--menu-field:#14221c;--menu-border:#92ac9270;--table-felt-top:#3d5b4c;--table-felt-bottom:#223d32;--table-wood:#484d3c;--table-trim:#bda67b}
body[data-theme=beach]{--gold:#efba95;--gold-light:#ffe2bc;--gold-dim:#bd8e6c;--ink:#122c32;--panel:#214149;--panel-soft:#34565d;--text:#fff8e7;--muted:#c8d9d7;--line:#e2e9d524;--ambient-color:#e8c5a0;--ambient-rgb:179,179,146;--avatar-edge:#cadad3;--menu-surface:#223f46;--menu-field:#122b33;--menu-border:#9cbdb770;--table-felt-top:#467f78;--table-felt-bottom:#245752;--table-wood:#8b7251;--table-trim:#efc9a0}
body[data-theme=lodge]{--gold:#dbac78;--gold-light:#f3d2a7;--gold-dim:#a67e55;--ink:#211b17;--panel:#342b23;--panel-soft:#493b2d;--text:#faf0de;--muted:#d1c2ad;--line:#e5cfaf24;--ambient-color:#dbb287;--ambient-rgb:177,128,81;--avatar-edge:#c5b296;--menu-surface:#332a22;--menu-field:#211a15;--menu-border:#b79b7670;--table-felt-top:#3e5949;--table-felt-bottom:#243d31;--table-wood:#66472e;--table-trim:#c39466}
body[data-theme=arcade] .scene-backdrop{background-image:url('/assets/world-arcade.jpg');background-position:50% 45%}
body[data-theme=haunted] .scene-backdrop{background-image:url('/assets/world-haunted.jpg');background-position:50% 45%}
body[data-theme=beach] .scene-backdrop{background-image:url('/assets/world-beach.jpg');background-position:50% 48%}
body[data-theme=lodge] .scene-backdrop{background-image:url('/assets/world-lodge.jpg');background-position:50% 45%}
body[data-theme=arcade] .scene-backdrop::after{background-image:radial-gradient(circle at 12% 28%,#badff0 0 1px,transparent 2px),radial-gradient(circle at 80% 62%,#ead4bc 0 1px,transparent 2px);background-size:260px 290px;opacity:.15;animation:world-stars 10s ease-in-out infinite alternate}
body[data-theme=haunted] .scene-backdrop::after{background-image:radial-gradient(circle at 18% 38%,#c1d5ad 0 1px,transparent 2.5px),radial-gradient(circle at 72% 75%,#b9c7b5 0 1px,transparent 2px);background-size:340px 380px;opacity:.15;animation:world-dust 42s linear infinite}
body[data-theme=beach] .scene-backdrop::before{background:linear-gradient(180deg,#04212a30,transparent 32%,#071d2859),radial-gradient(ellipse at 50% 45%,transparent 15%,#03222b1f)}
body[data-theme=beach] .scene-backdrop::after{background-image:radial-gradient(circle at 18% 30%,#ffecd0 0 1px,transparent 2px),radial-gradient(circle at 70% 75%,#e6e5cb 0 1px,transparent 2px);background-size:370px 350px;opacity:.12;animation:world-dust 44s linear infinite}
body[data-theme=lodge] .scene-backdrop::after{background-image:radial-gradient(circle at 12% 72%,#efc087 0 1px,transparent 2.5px),radial-gradient(circle at 71% 46%,#e8b27e 0 1px,transparent 2px);background-size:280px 360px;opacity:.19;animation:world-dust 27s linear infinite}
@media(max-width:900px){body[data-theme=arcade] .scene-backdrop{background-position:72% 50%}body[data-theme=haunted] .scene-backdrop{background-position:68% 50%}body[data-theme=beach] .scene-backdrop{background-position:68% 50%}body[data-theme=lodge] .scene-backdrop{background-position:40% 50%}}
@media(max-width:600px){body[data-theme=arcade] .scene-backdrop{background-position:87% 50%}body[data-theme=haunted] .scene-backdrop{background-position:76% 50%}body[data-theme=beach] .scene-backdrop{background-position:76% 50%}body[data-theme=lodge] .scene-backdrop{background-position:20% 50%}}
@media(prefers-reduced-motion:reduce){body:is([data-theme=arcade],[data-theme=haunted],[data-theme=beach],[data-theme=lodge]) .scene-backdrop::after{animation:none!important}}
