/* Comfortable reading, earned achievements, and the established blue rift palette. */
.hero-dossier h2,.companion-copy strong,.medals-page h2,.item-body h2,.book-detail-body h2{overflow-wrap:anywhere;min-width:0;white-space:normal}
.profile-cover>div,.companion-copy,.companion-actions{min-width:0}.profile-stat>span,.profile-stat>small,.profile-passive p,.class-skill-list p,.numeric-skills small{font-size:13px;line-height:1.45}
.profile-resource strong{font-size:24px}.profile-stat>strong{font-size:24px}.profile-details dl{font-size:14px}.profile-details summary,.guide-details summary,.book-detail-body summary{min-height:44px;display:flex;align-items:center;cursor:pointer}
.companion-actions{display:flex;flex-wrap:wrap;gap:5px}.companion-actions button,.text-back,.favorite-toggle,.inventory-shortcuts button,.book-presets button,.medal-periods button,.outdoor-choice{min-height:44px;min-width:44px}
.item-modal-head button,.book-detail-top button,#sheet #closeSheet,.privacy-top button{min-width:44px;min-height:44px;line-height:1}
.book-detail-body p,.item-body p,.book-detail-body td,.item-body td{font-size:14px;line-height:1.5}.book-detail-body th,.item-body th{font-size:12px;line-height:1.4}
.gear-name,.book-slot>span{font-size:12px;line-height:1.3;overflow-wrap:anywhere}.gear-slot-label{font-size:10px}.bag-heading h3{scroll-margin-top:10px}
.inventory-shortcuts{display:flex;flex-wrap:wrap;gap:8px;margin:14px 0}.inventory-shortcuts button{flex:1;padding:8px 12px;font:13px system-ui}.inventory-shortcuts [aria-pressed=true],.medal-periods [aria-pressed=true],.favorite-toggle[aria-pressed=true]{background:#193349;border-color:#9ed3e6;color:#edf9ff}
.new-find{position:absolute;left:4px;top:4px;padding:3px 6px;border-radius:5px;background:#163b4c;color:#e0f9ff;border:1px solid #87c5dc;font:700 10px system-ui;z-index:2}.protected-item{position:absolute;left:5px;bottom:30px;color:#f4dba1;text-shadow:0 1px 4px #000;font-size:17px;z-index:2}.protected-note{color:#c8d9e3;font-size:12px}
.book-presets{margin:12px 0;border:1px solid #496579;border-radius:12px;padding:0 12px;background:#0b1623}.book-presets>summary{min-height:44px;cursor:pointer;padding:12px 0;font-size:14px}.book-presets>div{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.book-presets article{min-width:0;padding:10px;background:#142536;border-radius:8px}.book-presets h4{margin:0 0 7px}.book-presets p{font:12px/1.5 system-ui;color:#c4d5e2;overflow-wrap:anywhere}.book-presets article>div{display:flex;flex-wrap:wrap;gap:5px}.book-presets article button{padding:7px;font-size:12px;flex:1}
.skill-book-art .book-sigil{background:none;border-radius:0;filter:drop-shadow(0 0 2px #b9eaff66)}
.starter-choice{min-width:0;border:1px solid #688caa40;border-radius:12px;overflow:hidden;background:#0b1725}.starter-choice .starter-book{width:100%;height:auto;min-height:145px;border:0;border-radius:0}.starter-book p{font-size:14px;line-height:1.45}.starter-values{padding:0 12px 10px}.starter-values summary{font:13px system-ui;min-height:44px;display:flex;align-items:center;cursor:pointer;color:#b7dbea}.starter-values p{font:13px/1.5 system-ui;margin:0}.class-book-preview p{font-size:14px}
.recent-medals{border-top:1px solid #47627666;margin:18px 0;padding-top:14px}.recent-medals h3{margin:0}.recent-medal-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin:12px 0}.recent-medal-grid>p{grid-column:1/-1;font-size:14px;color:#bfd1e0}.recent-medal-grid button{padding:8px 4px;display:grid;justify-items:center;gap:6px;background:#0c1b29}.recent-medal-grid strong{font:12px/1.3 system-ui;overflow-wrap:anywhere}.recent-medal-grid small{font-size:11px;color:#bdccda}.medal-art{display:block;width:86px;height:96px;position:relative;flex:none}.medal-art img{width:100%;height:100%;object-fit:contain}.medal-art b{position:absolute;left:50%;bottom:15px;transform:translateX(-50%);font:700 13px Georgia;color:#f5e0af;background:#101e2b;border:1px solid #a5bbc8;border-radius:50%;width:23px;height:23px;display:grid;place-items:center}.medal-art[data-tier="1"]{filter:sepia(.25)}.medal-art[data-tier="4"],.medal-art[data-tier="5"]{filter:drop-shadow(0 0 5px #e3b96344)}.medal-art[data-tier="6"],.medal-art[data-tier="7"],.medal-art[data-tier="8"]{filter:drop-shadow(0 0 7px #87dafb66)}
.medal-intro,.medal-period-note{font:14px/1.5 system-ui;color:#c4d7e5}.medal-periods{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;margin:15px 0}.medal-periods button{font:13px/1.3 system-ui;padding:8px 4px}.medal-group{margin:12px 0;border:1px solid #45677f;border-radius:14px;background:#0d1b2a;overflow:hidden}.medal-group>summary{padding:10px 14px;display:flex;align-items:center;gap:10px;cursor:pointer;font:18px/1.3 Georgia}.medal-group>summary img{width:44px;height:50px;object-fit:contain}.medal-group>summary small{display:block;font:12px system-ui;color:#bbd0df;margin-top:4px}.medals-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;padding:12px}.medal-card{display:flex;flex-direction:column;align-items:center;gap:7px;min-width:0;text-align:center;border:1px solid #3b566b;border-radius:10px;padding:9px 5px;background:#142638}.medal-card strong{font:13px/1.3 system-ui}.medal-card small{font:11px/1.4 system-ui;color:#bfccd7}.medal-card.locked{background:#0b1623;border-color:#263e51}.medal-card.locked .medal-art{filter:grayscale(1);opacity:.35}.medals-grid>p{grid-column:1/-1;font-size:14px;color:#a9c0d1}.medal-next{display:grid;grid-template-columns:1fr auto;gap:8px;padding:8px 14px;font:12px/1.4 system-ui}.medal-next [role=progressbar]{grid-column:1/-1;height:5px;border-radius:6px;background:#050d16;overflow:hidden}.medal-next i,.poi-rank-progress i{height:100%;display:block;background:linear-gradient(90deg,#427d9a,#aee9f5)}
.own-medals-link{margin:12px 0}.friend-medals{font-size:12px;padding:8px 10px}.poi-rank-facts{display:grid;grid-template-columns:1fr 1fr 1.5fr;gap:8px;align-items:stretch;margin:4px 0 10px}.poi-rank-facts>span{position:relative;display:flex;flex-direction:column;justify-content:center;gap:4px;padding:9px;background:#142738;border:1px solid #4b718a;border-radius:10px;min-width:0;text-align:center}.poi-rank-facts small{font:10px/1.2 system-ui;letter-spacing:.8px;color:#b9d4e5}.poi-rank-facts b{font:700 21px/1.2 Georgia;color:#edf5fb}.poi-rank-facts>span:last-child b{font-size:16px}.poi-rank-facts .rank-gem{position:absolute;left:4px;top:4px;width:18px;height:18px}.poi-rank-progress{margin:0 0 14px}.poi-rank-progress [role=progressbar]{height:5px;background:#050d17;border-radius:5px;overflow:hidden}.poi-rank-progress small{display:block;text-align:right;margin-top:5px;font:12px/1.4 system-ui;color:#c1d8e7}
.action-preview{margin:0 0 7px;padding:9px 11px;border-left:2px solid #94d8f0;background:#101e2ce8;font:13px/1.4 system-ui;color:#eff8ff;overflow-wrap:anywhere}.team-feedback{font:13px/1.4 system-ui;text-align:center;margin:0 0 7px;color:#e0f4c5;padding:6px;background:#183024;border-radius:6px}
.atb-action strong{font-size:clamp(11px,2.9vw,14px);line-height:1.25;overflow-wrap:normal;hyphens:none;min-height:2.5em}.atb-action .action-cost{font-size:10px;line-height:1.35}.atb-actor .actor-name{white-space:normal;overflow-wrap:anywhere;font-size:12px;line-height:1.15}.atb-actor .actor-vitals{font-size:11px;line-height:1.3}.atb-enemies.staggered .actor-name{font-size:10px;line-height:1.15}.atb-enemies.staggered .actor-vitals{font-size:10px}.actor-timeout:empty{display:none}
.atb-battle .atb-stage{isolation:isolate;background-image:none;background-color:#0b1421;overflow:hidden}.atb-battle .atb-stage::before{content:"";position:absolute;inset:0;z-index:-1;background:linear-gradient(#07102058,#0e1e3560 48%,#080f1ee0),var(--battle-ground) center/cover no-repeat;transform:scale(var(--scene-zoom,1));transition:transform .35s ease;pointer-events:none}.atb-stage[data-scene=duel]{--scene-zoom:1.18}.atb-stage[data-scene=party]{--scene-zoom:1.07}.atb-stage[data-scene=horde]{--scene-zoom:1}
.atb-stage[data-scene=duel] .atb-enemies>.atb-actor,.atb-stage[data-scene=duel] .atb-heroes>.atb-actor{max-width:min(245px,calc(100% / var(--units,1)))}.atb-stage[data-scene=duel] .atb-enemies .battle-sprite,.atb-stage[data-scene=duel] .atb-heroes .battle-sprite{max-height:240px}.atb-stage[data-scene=duel]:has(.atb-heroes>.self:only-child) .atb-heroes{padding-inline:58px}
.atb-battle .damage-number{--float-lane:0;top:calc(27% + var(--float-lane) * 22px);font-size:22px;padding:2px 6px;border-radius:5px;background:#07111bd9;color:#ffe3b4;text-shadow:0 1px 3px #000;animation:readable-hit 2200ms ease-out both}.atb-battle .damage-number.heal{color:#c5f4b3}.atb-battle .damage-number.status,.atb-battle .damage-number.lifesteal,.atb-battle .damage-number.health-cost,.atb-battle .damage-number.shield{font-size:12px;line-height:1.35;max-width:150px;width:max-content;white-space:normal;animation-duration:2800ms}.atb-battle .damage-number.shield{color:#b7e7ff}
@keyframes readable-hit{0%{opacity:0;transform:translate(-50%,8px) scale(.9)}12%,78%{opacity:1;transform:translate(-50%,-5px) scale(1)}100%{opacity:0;transform:translate(-50%,-19px)}}
.comfort-settings{margin-top:18px;border-top:1px solid #456077;padding-top:16px}.outdoor-choice{display:flex;align-items:center;gap:12px;cursor:pointer}.outdoor-choice input{width:24px;height:24px;flex:none}.outdoor-choice span{font:15px system-ui}.outdoor-choice strong{display:block;font:12px/1.4 system-ui;color:#bfd4e3;margin-top:5px}
html[data-outdoor=true]{--ink:#fff;--muted:#dce9f4;--line:#8aaac0}
html[data-outdoor=true] dialog,html[data-outdoor=true] .atb-dock,html[data-outdoor=true] .bottom-nav,html[data-outdoor=true] .topbar{background:#071321;color:#fff;border-color:#a6c4d8}
html[data-outdoor=true] :is(p,small,td,th,label,summary,.muted,.actor-name,.actor-vitals,.class-role,.action-cost,.profile-stat span,.profile-stat small,.gear-name,.book-effect){color:#e7f1fa;text-shadow:none}
html[data-outdoor=true] :is(.gear-card,.book-slot,.profile-stat,.medal-card,.medal-group,.companion-card,.daily-quest,.book-presets article,.poi-rank-facts>span){background:#102538;border-color:#a1bed1}
html[data-outdoor=true] :is(button,input,select){border-color:#aac8dd}html[data-outdoor=true] .atb-action{background-color:#132d43}html[data-outdoor=true] .atb-action.action-ready{border-color:#e1f5ff}html[data-outdoor=true] .atb-life{height:8px}html[data-outdoor=true] .atb-life i{background:#b1ed79}
@media(max-width:600px){.medals-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.medal-art{width:70px;height:84px}.book-presets>div{grid-template-columns:1fr}.book-presets article>div{flex-wrap:nowrap}.book-presets article p{margin:6px 0}.companion-card{gap:9px}.companion-actions{flex-direction:column;align-items:stretch}.companion-copy strong{font-size:16px}.medal-next{grid-template-columns:1fr}.medal-next strong{text-align:right}.profile-stats{gap:8px}.atb-action .action-cost{font-size:10px}}
@media(max-width:360px){.medals-grid{gap:5px;padding:8px}.medal-card strong{font-size:12px}.recent-medal-grid strong{font-size:11px}.medal-art{width:62px;height:76px}.atb-action strong{font-size:11px}.atb-action .action-cost{font-size:9px}.atb-stage[data-scene=duel]:has(.atb-heroes>.self:only-child) .atb-heroes{padding-inline:50px}}
@media(max-height:650px){.action-preview{font-size:12px;padding:6px 8px;margin-bottom:5px}.atb-actor .actor-name{font-size:11px}.atb-enemies.staggered .actor-name{font-size:9px}.atb-enemies.staggered .actor-vitals{font-size:9px}.team-feedback{font-size:12px;margin-bottom:5px;padding:4px}}
@media(prefers-reduced-motion:reduce){.atb-battle .damage-number{animation:none;opacity:1}.atb-battle .atb-stage::before{transition:none}}
.atb-action strong{max-width:100%;white-space:normal;overflow-wrap:anywhere;line-height:1.15;text-align:center}
.atb-stage[data-scene=duel] .actor-status:empty{display:none}
@media(max-height:650px) and (max-width:700px){.atb-action{display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:98px;height:98px;gap:2px;padding:3px}.atb-action .ability-icon{width:40px;height:36px;flex:none}.atb-action strong{font-size:11px}.atb-action .action-cost{font-size:10px;line-height:1.2}.atb-action .action-affinity{font-size:9px;margin:0}.atb-stage[data-scene=duel]{grid-template-rows:16px minmax(0,1fr) 18px minmax(0,1fr)}}
