/* Viewing tools and one shared-canvas immersive presentation. */
.bh-disk-tools { margin-top: 18px; border-top: 1px solid rgba(232,180,110,.25); padding-top: 16px; }
.bh-disk-tools summary { cursor: pointer; color: var(--black-hole-amber); font-size: .85rem; font-weight: 700; padding: 6px 0; }
.bh-tool-fields { display: grid; gap: 12px; padding-top: 16px; }
.bh-tool-fields small, #bh-probe-status { color: var(--text-secondary); font-size: .75rem; line-height: 1.6; margin: 0; }
.bh-effect-toggles { display: grid; gap: 12px; padding: 8px 0; }
.black-hole-controls .bh-effect-toggles label { display: flex; align-items: center; gap: 10px; font-size: .8rem; font-weight: 500; }
.bh-effect-toggles input { width: 17px; height: 17px; accent-color: var(--black-hole-amber); }
.bh-tool-fields select { padding: 10px; border: 1px solid rgba(185,196,210,.35); border-radius: 6px; background: var(--surface-panel); color: var(--text-primary); font: inherit; font-size: .85rem; }
.bh-probe-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.bh-probe-actions button, .bh-immersive-launch, .bh-immersive-header button {
    min-height: 42px; padding: 10px 14px; border: 1px solid rgba(232,180,110,.4);
    border-radius: 7px; background: rgba(130,85,30,.1); color: var(--text-primary);
    font: inherit; font-size: .8rem; font-weight: 600; cursor: pointer;
}
.bh-immersive-launch { width: 100%; margin-top: 14px; }
.bh-immersive-launch i { margin-right: 8px; }
.bh-probe-actions button:disabled, .bh-immersive-launch:disabled { opacity: .45; cursor: not-allowed; }
.bh-disk-tools :focus-visible, .bh-immersive-launch:focus-visible, .bh-immersive-header button:focus-visible {
    outline: 2px solid var(--black-hole-amber); outline-offset: 3px;
}
.black-hole-controls.disk-active { max-height: calc(100% - 6rem); overflow-y: auto; overscroll-behavior: contain; scrollbar-color: #a58050 #111827; }
.bh-immersive-open { overflow: hidden; }
.bh-immersive-dialog:not([open]) { display: none; }
.bh-immersive-dialog[open] {
    --text-primary: #edf2f8; --text-secondary: #b5c1d2; --surface-panel: #111722; --black-hole-amber: #edbb78;
    display: grid; grid-template-rows: auto minmax(0,1fr); position: fixed; inset: 0;
    width: 100vw; max-width: none; height: 100dvh; max-height: none;
    margin: 0; padding: 0; border: 0; background: #03050a; color: #edf2f8;
    overflow: hidden;
}
.bh-immersive-dialog::backdrop { background: #03050a; }
.bh-immersive-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding: 12px 24px; background: #080d15; border-bottom: 1px solid #34302a; }
.bh-immersive-header span { color: #a7b5c8; font-size: .65rem; letter-spacing: .08em; }
.bh-immersive-header h2 { margin: 3px 0 0; font-size: 1.05rem; text-align: left; }
.bh-immersive-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.bh-immersive-slot { min-height: 0; }
#bh-immersive-dialog .black-hole-playground { height: 100%; min-height: 0; padding: 0; border: 0; }
#bh-immersive-dialog .black-hole-scene { height: 100%; min-height: 0; }
#bh-immersive-dialog .black-hole-scene > canvas { height: 100% !important; width: 100% !important; }
#bh-immersive-dialog .black-hole-controls {
    position: absolute; z-index: 6; top: 16px; left: 16px; margin: 0;
    width: min(340px, calc(100% - 32px)); max-height: calc(100% - 32px); overflow-y: auto;
    background: rgba(8,14,24,.95); color: #edf2f8; border: 1px solid #655038;
}
#bh-immersive-dialog:not(.bh-controls-visible) .black-hole-controls { display: none; }
#bh-immersive-dialog .black-hole-mode-selector, #bh-immersive-dialog .black-hole-mode-summary,
#bh-immersive-dialog .bh-immersive-launch, #bh-immersive-dialog .black-hole-legend { display: none; }
#bh-immersive-dialog .black-hole-scene-actions { position: absolute; top: 16px; right: 24px; max-width: none; padding: 0; background: transparent; }
#bh-immersive-dialog .black-hole-scene-actions p, #bh-immersive-dialog #bh-runtime-indicator { display: none; }
#bh-immersive-dialog.bh-controls-visible .black-hole-scene-actions { display: none; }
.bh-cockpit { position: absolute; inset: 12px 12px 20px; pointer-events: none; z-index: 2; border-radius: 28px; border: 1px solid rgba(185,202,219,.25); box-shadow: inset 0 0 55px 12px rgba(0,0,0,.45); }
.bh-cockpit-readouts { position: absolute; top: 26px; left: 32px; z-index: 3; max-width: min(450px,calc(100% - 220px)); pointer-events: none; }
.bh-cockpit-readouts > span { display: block; color: #e8b779; font-size: .62rem; text-transform: uppercase; letter-spacing: .16em; margin-bottom: 8px; }
.bh-cockpit-readouts output { display: block; color: #cfdae7; font-size: .76rem; line-height: 1.8; text-shadow: 0 1px 5px #000; }
@media (max-width: 900px) {
    .black-hole-controls.disk-active { max-height: none; overflow: visible; }
}
@media (max-width: 600px) {
    .bh-immersive-header { padding: 10px 16px; gap: 10px; }
    .bh-immersive-header h2 { font-size: .95rem; }
    .bh-immersive-header button { font-size: .7rem; padding: 8px 10px; }
    .bh-immersive-actions { width: 100%; }
    .bh-cockpit-readouts { left: 26px; top: 72px; max-width: calc(100% - 52px); }
}
