#hud .inventory-tabs button { width:20%; }
#hud .inventory-grid.prayerbook-open { width:min(364px,calc(100vw - 24px));height:min(700px,calc(100dvh - 180px));max-height:calc(100dvh - 180px); }
#hud #prayer-panel { --ink:#e7dfc9;--muted:#b5b4a2;--rubric:#e3c68b;display:flex;flex:1;flex-direction:column;min-height:0;padding:10px;gap:8px;color:var(--ink);font:12px Georgia,serif;background:radial-gradient(ellipse at 50% 0,#64634d38,transparent 65%),linear-gradient(135deg,#46493e,#343b34);box-shadow:inset 0 0 0 1px #92836188,inset 0 0 0 3px #252b2555; }
#hud #prayer-panel[hidden],#hud #prayer-panel [hidden] { display:none; }
#hud #prayer-panel button { border:1px solid #9c90635c;border-radius:2px;padding:6px 8px;background:#242b255c;color:var(--ink);font:11px Georgia,serif;cursor:pointer; }
#hud #prayer-panel button:hover:not(:disabled),#hud #prayer-panel button[aria-pressed=true] { border-color:#c6b077;background:#9c885f33; }
#hud #prayer-panel button:disabled { opacity:.5;cursor:default; }
#hud #prayer-panel :is(button,select,input,summary):focus-visible { outline:2px solid #e9ce8d;outline-offset:2px; }
.prayer-heading { display:flex;justify-content:space-between;align-items:center;min-height:25px; }
#hud #prayer-panel .prayer-heading h3 { margin:0;color:#eed8a7;font:19px Georgia,serif; }
#hud #prayer-panel #prayer-level { color:#c0baa3;font-size:11px; }
.prayer-pages { display:flex;gap:4px;flex:none; }
#hud #prayer-panel .prayer-pages button { flex:1;min-width:0;min-height:31px;padding:5px 2px; }
#hud #prayer-panel .prayer-pages button[aria-pressed=true] { color:#f5dfab;background:linear-gradient(#8d7a4c66,#8d7a4c25);box-shadow:inset 0 -2px #c3a568; }
.prayer-content { flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#97875c66 transparent; }
#hud #prayer-panel .prayer-content h4 { font:17px Georgia,serif;color:var(--rubric);margin:12px 0 7px; }
.prayer-content p { line-height:1.45; }
#hud #prayer-panel .prayer-intro { color:var(--muted);font-size:11px; }
.prayer-icon-grid { display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:3px;padding:5px;background:#20291f38;border:1px solid #a08e6166;box-shadow:inset 0 1px 5px #0f170f55; }
#hud #prayer-panel .prayer-icon-button { position:relative;display:grid;place-items:center;min-width:0;height:55px;padding:3px 5px 8px;border:1px solid transparent;border-radius:3px;background:transparent;isolation:isolate; }
#hud #prayer-panel .prayer-icon-button .icon { width:43px;height:43px;max-width:100%;object-fit:contain;filter:var(--prayer-art-filter,drop-shadow(0 1px 1px #111c));transition:opacity .12s; }
#hud #prayer-panel .prayer-icon-button.inspected { border-color:#a6997055;background:#dfd1a410; }
#hud #prayer-panel .prayer-icon-button:hover { background:#dcc58418;border-color:#c6b07799; }
#hud #prayer-panel .prayer-icon-button[aria-pressed=true] { background:radial-gradient(ellipse,#b59d6855,#b59d6815);border-color:#d0b16f;box-shadow:inset 0 0 0 1px #1c241dcc,0 0 5px #b2954c28; }
#hud #prayer-panel .prayer-icon-button.locked .icon { opacity:.36;filter:grayscale(.5) var(--prayer-art-filter,drop-shadow(0 1px 1px #111)); }
#hud #prayer-panel .prayer-icon-button.locked { cursor:help; }
#hud #prayer-panel .prayer-icon-level { position:absolute;bottom:1px;right:4px;color:#cdc6af;font:9px Georgia,serif;line-height:12px;text-shadow:0 1px 2px #111; }
#hud #prayer-panel .prayer-icon-button.locked .prayer-icon-level { color:#a69b87; }
/* Tier accents follow the artwork's silhouette, leaving the gold active frame distinct. */
#hud #prayer-panel [data-prayer-family=focus] { --prayer-accent:#dbae61;--prayer-exalted:#efd384;--prayer-hue-2:-8deg;--prayer-hue-3:5deg; }
#hud #prayer-panel [data-prayer-family=might], #hud #prayer-panel [data-prayer-family=prowess] { --prayer-accent:#d99e80;--prayer-exalted:#eb9683;--prayer-hue-2:-34deg;--prayer-hue-3:-50deg; }
#hud #prayer-panel [data-prayer-family=resolve] { --prayer-accent:#82bdcc;--prayer-exalted:#a3cfe9;--prayer-hue-2:152deg;--prayer-hue-3:175deg; }
#hud #prayer-panel [data-prayer-family=marksman] { --prayer-accent:#94c58a;--prayer-exalted:#83d6b7;--prayer-hue-2:70deg;--prayer-hue-3:115deg; }
#hud #prayer-panel [data-prayer-family=arcane] { --prayer-accent:#b9a0d9;--prayer-exalted:#d8ace6;--prayer-hue-2:220deg;--prayer-hue-3:250deg; }
/* Zero-blur contours stay opaque; the artwork itself carries each tier's shade. */
#hud #prayer-panel [data-prayer-tier="2"] { --prayer-art-filter:sepia(.55) saturate(1.35) hue-rotate(var(--prayer-hue-2)) brightness(1.02) drop-shadow(.5px 0 0 var(--prayer-accent)) drop-shadow(-.5px 0 0 var(--prayer-accent)) drop-shadow(0 .5px 0 var(--prayer-accent)) drop-shadow(0 -.5px 0 var(--prayer-accent)); }
#hud #prayer-panel [data-prayer-tier="3"] { --prayer-art-filter:sepia(.68) saturate(1.75) hue-rotate(var(--prayer-hue-3)) brightness(1.04) drop-shadow(.65px 0 0 var(--prayer-exalted)) drop-shadow(-.65px 0 0 var(--prayer-exalted)) drop-shadow(0 .65px 0 var(--prayer-exalted)) drop-shadow(0 -.65px 0 var(--prayer-exalted)); }
/* A single fine, antialiased edge preserves rings and leaf gaps without stacked contour buildup. */
#hud #prayer-panel :is([data-prayer-family=focus],[data-prayer-family=marksman])[data-prayer-tier="2"] { --prayer-art-filter:sepia(.46) saturate(1.5) hue-rotate(var(--prayer-hue-2)) brightness(1.05) drop-shadow(0 0 .5px var(--prayer-accent)); }
#hud #prayer-panel :is([data-prayer-family=focus],[data-prayer-family=marksman])[data-prayer-tier="3"] { --prayer-art-filter:sepia(.64) saturate(1.9) hue-rotate(var(--prayer-hue-3)) brightness(1.12) drop-shadow(0 0 .7px var(--prayer-exalted)); }
#hud #prayer-panel .prayer-active-mark { position:absolute;top:1px;left:3px;display:none;font:11px Georgia,serif;color:#eed499; }
#hud #prayer-panel .prayer-icon-button[aria-pressed=true] .prayer-active-mark { display:block; }
.prayer-detail { min-height:78px;margin:8px 0;padding:9px 10px;border:1px solid #9c906344;background:#242b2540; }
.prayer-detail-heading { display:flex;justify-content:space-between;gap:8px;align-items:baseline; }
#hud #prayer-panel .prayer-detail-heading strong { font:14px Georgia,serif;color:#f1d7a0; }
#hud #prayer-panel .prayer-detail-state { color:#bcb89e;font-size:10px;flex:none; }
#hud #prayer-panel .prayer-detail-state.on { color:#d8cf84; }
.prayer-detail p { margin:6px 0;min-height:16px;font-size:11px; }
.prayer-detail small { display:block;font-size:10px; }
#hud #prayer-panel .prayer-lock-note { color:#d9ab8a;margin-top:5px; }
.prayer-presets { display:flex;gap:6px;align-items:center; }
.prayer-presets span { display:flex;flex:1;gap:2px; }
#hud #prayer-panel .prayer-presets button { min-height:29px;padding:5px 8px; }
.prayer-help { margin-top:10px;font-size:10px; }
.prayer-help summary,.ritual-stage-guide summary { cursor:pointer;padding:4px 0;color:var(--muted); }
.prayer-help p { margin:7px 0; }
.prayer-empty { padding:16px 8px;text-align:center;line-height:1.5; }
.prayer-empty button { display:block;margin:12px auto 0; }
.prayer-footer { display:flex;flex:none;align-items:center;justify-content:space-between;gap:10px;border-top:1px solid #ad95615c;padding-top:8px; }
.prayer-points { display:flex;align-items:center;gap:7px; }
.prayer-points .icon { width:25px;height:25px; }
#hud #prayer-panel [data-prayer-points] { display:block;font:17px Georgia,serif;color:#eed18c; }
#hud #prayer-panel [data-prayer-drain] { display:block;font-size:9px;margin-top:2px;color:var(--muted); }
#hud #prayer-panel [data-ui=filters] { min-width:65px;min-height:31px; }
.prayer-filters { display:flex;align-items:end;gap:6px;padding:8px;margin-bottom:8px;border:1px solid #a08e6166;background:#20271e55; }
.prayer-filters label { flex:1;min-width:0; }
#hud #prayer-panel label { font-size:10px;color:var(--muted); }
#hud #prayer-panel select { display:block;width:100%;min-width:0;height:30px;padding:4px;margin-top:4px;border:1px solid #9c90636b;border-radius:2px;background:#30382e;color:var(--ink);font:11px Georgia,serif;color-scheme:dark; }
#hud #prayer-panel .prayer-filters button { height:30px;padding:4px 6px; }
.ritual-icon-grid { margin-bottom:7px; }
#hud #prayer-panel .ritual-icon-grid .prayer-icon-button { height:51px; }
#hud #prayer-panel .ritual-icon-grid .icon { width:44px;height:44px; }
.ritual-hero { display:flex;align-items:center;gap:9px;margin-top:3px;padding:0 5px; }
.ritual-hero>.icon { width:35px;height:35px;flex:none; }
#hud #prayer-panel[data-ritual-theme=moonwell] { --ritual-accent:#b5dbe0;--ritual-wash:#7faec318; }
#hud #prayer-panel[data-ritual-theme=orrery] { --ritual-accent:#d1bce8;--ritual-wash:#ad8bd118; }
#hud #prayer-panel[data-ritual-theme=dawn] { --ritual-accent:#f0d39a;--ritual-wash:#e9b86d18; }
.ritual-hero.featured { min-height:87px;gap:8px;padding:6px 7px;border:1px solid #b8a78455;background:radial-gradient(ellipse at 12% 50%,var(--ritual-wash),transparent 75%),#1c252330;box-shadow:inset 0 1px #eadcb30c; }
.ritual-hero.featured>.icon { width:78px;height:78px;object-fit:contain;filter:drop-shadow(0 3px 4px #101b2299); }
.ritual-hero.featured>div { min-width:0; }
#hud #prayer-panel .ritual-hero.featured h4 { color:var(--ritual-accent);font-size:17px;line-height:1.15;margin:5px 0; }
#hud #prayer-panel .ritual-epithet { display:block;color:var(--ritual-accent);opacity:.85;font:italic 10px Georgia,serif; }
.ritual-composition { display:block;margin-top:5px;font-size:9px;color:var(--muted); }
.ritual-composition i { padding:0 3px;font-style:normal; }
#hud #prayer-panel .ritual-blessing { margin:0 0 7px;padding:0 2px;color:var(--ritual-accent);font-size:10px; }
.ritual-sequence { display:flex;justify-content:space-between;gap:5px;margin:10px 0 12px; }
.ritual-sequence>span { position:relative;display:grid;place-items:center;flex:1;height:23px;border-bottom:2px solid #a48b5a44;color:var(--muted);font-size:10px; }
.ritual-sequence>.current { color:var(--ritual-accent);border-color:var(--ritual-accent);background:var(--ritual-wash); }
.ritual-sequence>.complete { color:#c4cea7;border-color:#9cae77; }
#hud #prayer-panel .ritual-next { color:var(--muted);font-size:10px;line-height:1.4;margin:10px 0; }
.ritual-total { display:flex;align-items:center;gap:10px;padding-top:8px;border-top:1px solid #a3895433; }
.ritual-total small { flex:none;font-size:9px;color:var(--muted); }
.ritual-total progress { height:3px; }
#hud #prayer-panel .ritual-hero small { font-size:9px;color:var(--muted);letter-spacing:.04em; }
#hud #prayer-panel .ritual-hero h4 { font-size:16px;margin:3px 0; }
.ritual-metrics { display:grid;grid-template-columns:repeat(3,minmax(0,1fr));margin:5px 0 7px;padding:4px 0;background:#1e281d3d;border:1px solid #9c906344; }
.ritual-metrics>span { text-align:center;padding:0 2px; }
.ritual-metrics>span+span { border-left:1px solid #9c906333; }
#hud #prayer-panel .ritual-metrics strong { display:block;font:14px Georgia,serif;color:#e4cf9a; }
.ritual-metrics small { display:block;margin-top:2px;font-size:9px; }
.ritual-setup { display:grid;grid-template-columns:minmax(0,1fr);gap:7px; }
.ritual-setup label { min-width:0; }
.ritual-supply-heading { display:flex;justify-content:space-between;align-items:center;font-size:10px;margin:7px 0 4px; }
#hud #prayer-panel .ritual-supply-heading>span { color:#bac49e; }
.ritual-supplies { display:grid;grid-template-columns:repeat(auto-fit,minmax(65px,1fr));gap:4px; }
.ritual-supply { display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;min-width:0;padding:4px;border:1px solid #9c906333;background:#252e2355;text-align:center; }
.ritual-supply>.icon { width:23px;height:23px;object-fit:contain; }
.ritual-supply>span { max-width:100%;font-size:9px; }
#hud #prayer-panel .ritual-supply small { display:block;font-size:10px;margin-top:2px;color:#c0cd9d; }
.ritual-supply.missing { border-color:#cb8b6055; }
#hud #prayer-panel .ritual-supply.missing small { color:#ecb28b; }
#hud #prayer-panel .ritual-repeat { display:flex;align-items:center;gap:6px;padding:8px 0;cursor:pointer;font-size:11px; }
.ritual-repeat input { margin:0;accent-color:#b29a5d;flex:none; }
#hud #prayer-panel .ritual-begin { width:100%;min-height:34px;background:linear-gradient(#9a8152,#74613e);border:1px solid #c0a572;color:#fff0ce;font-size:12px;box-shadow:inset 0 1px #e4ce9840; }
#hud #prayer-panel .ritual-begin:hover:not(:disabled) { background:linear-gradient(#aa8f5c,#887249); }
#hud #prayer-panel .ritual-begin:disabled { opacity:1;background:#bba46b19;color:#a8a18c;border-color:#9c906344; }
#hud #prayer-panel .ritual-start-hint { color:#d4b795;font-size:10px;margin:5px 0; }
#hud #prayer-panel .ritual-location { font-size:10px;color:var(--muted);margin:5px 0; }
.ritual-current { padding:10px;margin-top:8px;background:#c5a76315;border:1px solid #a3895466; }
.ritual-current>small { font-size:9px;letter-spacing:.06em; }
.ritual-current>strong { display:block;margin:5px 0 8px;font-size:13px;font-weight:normal; }
.ritual-current>span { display:block;text-align:right;font-size:10px;margin-top:6px; }
.altar-prayer-steps { display:flex;align-items:center;justify-content:space-between;gap:8px;padding:3px 0 12px;border-bottom:1px solid #a3895433;margin-bottom:12px; }
.altar-prayer-steps>span { display:flex;align-items:center;gap:5px;font-size:11px;color:#8c816b; }
.altar-prayer-steps i { display:grid;place-items:center;width:20px;height:20px;border:1px solid #a3895466;border-radius:50%;font-size:10px;font-style:normal; }
.altar-prayer-steps .current { color:#e4cc98; }
.altar-prayer-steps .current i { border-color:#cbb176;background:#bda26a26;box-shadow:0 0 0 3px #bda26a0c; }
.altar-prayer-steps .complete { color:#b6b590; }
.altar-prayer-steps .complete i { border-color:#a8ac7c;background:#a8ac7c20; }
.ritual-current progress,.ritual-status progress { display:block;width:100%;height:6px;border:none;background:#9e896038;accent-color:#bda26a;border-radius:3px;overflow:hidden; }
.ritual-current progress::-webkit-progress-bar,.ritual-status progress::-webkit-progress-bar { background:#9e896038; }
.ritual-current progress::-webkit-progress-value,.ritual-status progress::-webkit-progress-value { background:linear-gradient(90deg,#927749,#dcc28a);border-radius:3px; }
.ritual-current progress::-moz-progress-bar,.ritual-status progress::-moz-progress-bar { background:linear-gradient(90deg,#927749,#dcc28a); }
.prayer-actions { display:flex;gap:6px; }.prayer-actions button { flex:1; }
.ritual-stages { padding:0;margin:8px 0;list-style:none;line-height:1.4; }
.ritual-stages li { display:flex;align-items:center;gap:7px;padding:6px;border-left:2px solid #a48b5a44;font-size:10px; }
.ritual-stage-number { display:grid;place-items:center;width:20px;height:20px;border:1px solid #b39a6c77;border-radius:50%;flex:none;font-size:9px; }
.ritual-stages small { display:block;font-size:9px;margin-top:2px;font-weight:normal; }
#hud #prayer-panel .ritual-stages .current { background:#b89a5233;color:#f3db9f;border-left-color:#d5b779; }
.ritual-stages .complete .ritual-stage-number { background:#81915f38;border-color:#9eab80; }
.ritual-stage-guide { margin:6px 0;font-size:10px; }
.ritual-receipt { display:flex;align-items:center;gap:8px;padding:7px;margin-top:6px;background:#91a47722;border:1px solid #7f946d66;font-size:10px; }
.ritual-receipt .icon { width:18px;height:18px; }.ritual-receipt strong { display:block;font-size:12px;margin-top:3px;font-weight:normal; }
#hud.ritual-active #interaction { visibility:hidden; }
#hud .ritual-status progress { margin:10px 0 7px; }
#hud .ritual-status-detail { font-size:10px;color:#766347; }
#hud #prayer-panel .prayer-message { padding:6px 8px;margin:0;border-left:2px solid #c3a364;background:#222a2040;font-size:11px; }
.prayer-content dl { display:grid;grid-template-columns:1fr auto;gap:8px; }.prayer-content dd { margin:0; }
#prayer-vitals { display:flex;gap:5px;align-items:center;color:#735732;font:12px Georgia,serif;padding:0 7px;border-left:1px solid #a08252; }
#prayer-vitals .icon { width:22px;height:22px; }#prayer-vitals.active { background:#b9a16444; }
@media(max-width:600px) { #hud:has(#inventory.prayerbook-open:not([hidden])) .map-cluster { visibility:hidden;pointer-events:none; } }
@media(max-width:380px) { #hud #prayer-panel { padding:8px;gap:6px; }#hud #prayer-panel .prayer-icon-button { height:51px; }.prayer-icon-grid { padding:3px;gap:2px; }#hud #prayer-panel .prayer-icon-button .icon { width:39px;height:39px; } }
@media(max-height:700px) { #hud .inventory-grid.prayerbook-open { height:calc(100dvh - 150px);max-height:calc(100dvh - 150px); } }
