        :root {
            --rum-primary: #2A6DB0;
            --rum-btn: #f6a868;
            --stroke: rgba(255, 255, 255, 0.12);
            --glass-bg: rgba(255, 255, 255, 0.05);
            --nav-height: 0px;
            --bg: #02030a;
            --bg-soft: #0b1020;
            --text: #f8fafc;
            --muted: rgba(226, 232, 240, 0.78);
            --line: rgba(255, 255, 255, 0.12);
            --brand: #f6a868;
            --accent-text: #ffd2ab;
            --accent-text-hover: #fff1df;
            --accent-border-strong: rgba(246, 168, 104, 0.55);
            --sky: #66c8ff;
            --panel-border: rgba(246, 168, 104, 0.5);
            --panel-bg: linear-gradient(180deg, rgba(16, 19, 32, 0.98), rgba(9, 11, 20, 0.99));
            --card-inset: inset 0 1px 0 rgba(255, 255, 255, 0.03);
            --shadow: 0 20px 70px rgba(2, 8, 23, 0.32);
            --radius: 24px;
            --radius-sm: 16px;
            --sunMix: 0%;
            --dayOp: 0;
            --starsOpacity: 0.95;
            --satOp: 0.92;
            --seaOp: 0;
            --bgShift: 0px;
            --seaY: 0px;
        }

        * { box-sizing: border-box; }
        html, body { min-height: 100%; }
        body {
            margin: 0;
            font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
            background: var(--bg);
            color: var(--text);
            overflow-x: hidden;
            overflow-y: auto;
        }

        /* Fondo vivo (mismo sistema que index.php) */
        .world {
            position: fixed;
            inset: 0;
            z-index: -3;
            pointer-events: none;
            overflow: hidden;
        }
        .world .bg {
            position: absolute;
            inset: 0;
            background:
                linear-gradient(180deg,
                    color-mix(in srgb, #02030a calc(100% - var(--sunMix)), #2a0f35 var(--sunMix)) 0%,
                    color-mix(in srgb, #08101d calc(100% - var(--sunMix)), #7c361a var(--sunMix)) 56%,
                    color-mix(in srgb, #10192c calc(100% - var(--sunMix)), #ffbb72 var(--sunMix)) 100%
                );
            transform: translate3d(0, var(--bgShift), 0);
            transition: background 500ms ease;
        }
        @supports not (background: color-mix(in srgb, #000 50%, #fff 50%)) {
            .world .bg { background: linear-gradient(180deg, #02030a 0%, #08101d 56%, #7c361a 84%, #ffbb72 100%); }
        }
        .world .daywash {
            position: absolute;
            inset: 0;
            background: linear-gradient(180deg, #c7edff 0%, #8bd6ff 52%, #e8f6ff 100%);
            opacity: var(--dayOp);
            mix-blend-mode: screen;
            transition: opacity 0.7s ease;
        }
        #rumCoordStarsCanvas {
            position: absolute;
            inset: 0;
            width: 100%;
            height: 100%;
            opacity: var(--starsOpacity);
            transition: opacity 0.6s ease;
        }
        .world .layer {
            position: absolute;
            inset: -12vh 0 -12vh 0;
            transform: translate3d(0, var(--shift, 0px), 0);
            opacity: var(--op, 1);
            transition: opacity 0.7s ease;
        }
        .world .satellites { --op: var(--satOp); }
        .world .sea { --op: var(--seaOp); }
        .world .satDot {
            position: absolute;
            left: -12vw;
            top: var(--y, 10vh);
            width: 3px;
            height: 3px;
            border-radius: 999px;
            background: rgba(255, 255, 255, 0.96);
            box-shadow: 0 0 8px rgba(255, 255, 255, 0.42), 0 0 18px rgba(102, 200, 255, 0.16);
            opacity: 0.95;
            animation: rumCoordSatFly var(--t, 24s) linear infinite;
            animation-delay: var(--d, 0s);
        }
        .world .satDot::after {
            content: "";
            position: absolute;
            left: -10px;
            top: 50%;
            width: 14px;
            height: 2px;
            transform: translateY(-50%);
            background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.28));
            opacity: 0.55;
        }
        @keyframes rumCoordSatFly {
            0% { transform: translate3d(-10vw, 0, 0); opacity: 0; }
            8%, 92% { opacity: 0.95; }
            100% { transform: translate3d(124vw, 0, 0); opacity: 0; }
        }
        .world .seaBand {
            position: absolute;
            left: -10vw;
            right: -10vw;
            bottom: -10vh;
            height: 42vh;
            background:
                radial-gradient(850px 260px at 50% 28%, rgba(102, 200, 255, 0.18), transparent 62%),
                linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, rgba(13, 22, 42, 0.18) 35%, rgba(13, 22, 42, 0.5) 100%);
            border-top-left-radius: 60% 38%;
            border-top-right-radius: 60% 38%;
            transform: translate3d(0, var(--seaY), 0);
        }

        .rum-coord-page-wrap.page-wrap {
            position: relative;
            z-index: 2;
        }

        .topbar {
            height: 75px;
            position: relative;
            z-index: 100;
            display: flex;
            align-items: center;
            padding: 0 30px;
            justify-content: space-between;
            border-bottom: 1px solid var(--panel-border);
            background: var(--panel-bg);
            box-shadow: 0 18px 40px rgba(2, 8, 23, 0.28), var(--card-inset);
            backdrop-filter: blur(14px);
        }
        .brand {
            font-family: 'Baloo 2', system-ui, sans-serif;
            font-weight: 800;
            font-size: 26px;
            color: #fff;
        }
        .brand span {
            color: var(--brand);
            text-shadow: 0 0 20px rgba(246, 168, 104, 0.35);
        }

        .main-layout { display: grid; grid-template-columns: minmax(360px, 1fr) minmax(0, 1fr); height: calc(100vh - 75px - var(--nav-height)); position: relative; z-index: 2; gap: 16px; padding: 18px; }
        @media (min-width: 1600px){
            .main-layout {
                grid-template-columns: minmax(420px, 1fr) minmax(0, 1fr);
            }
        }

        .main-layout--issues-only {
            grid-template-columns: minmax(300px, 420px) minmax(0, 1fr);
            align-items: stretch;
        }
        @media (min-width: 1600px) {
            .main-layout--issues-only {
                grid-template-columns: minmax(340px, 460px) minmax(0, 1fr);
            }
        }

        .issues-workbench-panel {
            display: flex;
            flex-direction: column;
            gap: 14px;
            min-height: 0;
            max-height: calc(100vh - 75px - var(--nav-height));
            overflow-x: hidden;
            overflow-y: auto;
            padding: 2px 8px 16px 0;
            scrollbar-gutter: stable;
        }
        .issues-workbench-header {
            padding: 4px 2px 8px;
        }
        .issues-workbench-title {
            margin: 0 0 8px;
            font-family: 'Baloo 2', system-ui, sans-serif;
            font-size: 1.25rem;
            color: var(--text);
            line-height: 1.15;
        }
        .issues-workbench-lede {
            margin: 0;
            font-size: 13px;
            line-height: 1.55;
            color: var(--muted);
        }
        .issues-workbench-lede strong {
            color: rgba(255, 241, 223, 0.92);
        }
        .issues-workbench-card {
            background:
                radial-gradient(circle at 100% 0%, rgba(102, 200, 255, 0.08), transparent 45%),
                linear-gradient(165deg, rgba(248, 250, 252, 0.97), rgba(236, 242, 252, 0.94));
            border: 1.5px solid rgba(246, 168, 104, 0.28);
            border-radius: var(--radius-sm);
            padding: 14px 14px 16px;
            color: #0f172a;
            box-shadow: 0 10px 32px rgba(2, 8, 23, 0.1);
        }
        .issues-workbench-card-title {
            margin: 0 0 12px;
            font-family: 'Baloo 2', system-ui, sans-serif;
            font-size: 1.02rem;
            color: #0f172a;
            border-bottom: 1px solid rgba(15, 23, 42, 0.1);
            padding-bottom: 8px;
        }
        .issues-compact-form .command-form label {
            color: rgba(15, 23, 42, 0.65);
        }
        .issues-strategy-hint {
            margin-top: 12px;
            padding: 10px 12px;
            border-radius: 12px;
            background: rgba(42, 109, 176, 0.08);
            border: 1px solid rgba(42, 109, 176, 0.22);
            font-size: 12px;
            line-height: 1.5;
            color: #334155;
        }
        .issues-strategy-hint strong {
            color: #0f172a;
        }
        .issues-plan-table-wrap {
            margin-top: 12px;
            max-height: min(420px, 48vh);
        }
        body.rum-mc-clash-table-expanded .issues-plan-table-wrap,
        body.rum-mc-clash-table-expanded #clashTableWrapper.table-wrapper,
        body.rum-mc-clash-table-expanded #clash-detection-card .table-wrapper {
            max-height: min(720px, 62vh);
        }
        .rum-mc-clash-setup-toggle {
            width: 100%;
            text-align: left;
            font-size: 12px;
            color: #334155;
        }
        .issues-plan-table select,
        .issues-plan-table input[type="text"] {
            width: 100%;
            max-width: 100%;
            font-size: 11px;
            padding: 5px 6px;
            border-radius: 8px;
            border: 1px solid rgba(42, 109, 176, 0.35);
            background: #fff;
            color: #0f172a;
        }
        .issues-plan-table th,
        .issues-plan-table td {
            vertical-align: middle;
            font-size: 11px;
        }
        .issues-plan-table .issues-plan-summary {
            max-width: 120px;
            word-break: break-word;
        }

        .issues-viewer-column {
            display: flex;
            flex-direction: column;
            min-height: 0;
            min-width: 0;
            gap: 10px;
            background: var(--panel-bg);
            border: 1.5px solid var(--panel-border);
            border-radius: var(--radius);
            padding: 12px;
            box-shadow: 0 18px 40px rgba(2, 8, 23, 0.28), var(--card-inset);
            backdrop-filter: blur(12px);
        }
        .issues-viewer-toolbar {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 12px;
            flex-wrap: wrap;
        }
        .issues-viewer-label {
            font-family: 'Baloo 2', system-ui, sans-serif;
            font-size: 0.95rem;
            color: #fff;
            letter-spacing: 0.02em;
        }

        /* Plano de sección (clipping) — Model Coordination */
        .rum-mc-section-tools {
            display: grid;
            gap: 10px;
            margin-top: 12px;
            padding-top: 12px;
            border-top: 1px solid var(--line);
            font-size: 12px;
            color: var(--muted);
        }
        .rum-mc-section-tools__row {
            display: grid;
            gap: 6px;
        }
        .rum-mc-section-tools__row label {
            font-weight: 600;
            color: var(--text);
        }
        .rum-mc-section-tools select,
        .rum-mc-section-tools__select {
            width: 100%;
            max-width: 280px;
            padding: 6px 8px;
            border-radius: 10px;
            border: 1px solid var(--line);
            background: rgba(15, 23, 42, 0.55);
            color: var(--text);
            font-size: 12px;
        }
        .rum-mc-section-tools input[type="range"],
        .rum-mc-section-tools__range {
            width: 100%;
            max-width: 280px;
            accent-color: #f6a868;
            transition: opacity 0.2s ease;
        }
        .rum-mc-section-tools__value {
            font-variant-numeric: tabular-nums;
            color: var(--accent-text);
            font-weight: 600;
        }
        .rum-mc-section-tools--compact {
            display: flex;
            flex-wrap: wrap;
            align-items: center;
            gap: 8px 10px;
            margin-top: 0;
            padding-top: 0;
            border-top: none;
            font-size: 11px;
        }
        .rum-mc-section-tools--compact .rum-mc-section-tools__label {
            font-weight: 700;
            text-transform: uppercase;
            letter-spacing: 0.06em;
            color: rgba(248, 250, 252, 0.85);
        }
        .rum-mc-section-tools--compact .rum-mc-section-tools__select {
            max-width: 72px;
            padding: 4px 6px;
        }
        .rum-mc-section-tools--compact .rum-mc-section-tools__range {
            width: min(140px, 28vw);
            max-width: 140px;
        }
        .issues-viewer-stage {
            flex: 1;
            min-height: clamp(380px, 62vh, 920px);
            display: flex;
            flex-direction: column;
            min-width: 0;
        }
        .issues-viewer-stage .rum-viewer-widget,
        .issues-viewer-stage .rum-viewer-widget__layout {
            flex: 1;
            min-height: 0;
            display: flex;
            flex-direction: column;
        }
        .issues-viewer-stage .viewer-shell {
            flex: 1;
            min-height: 360px;
            height: auto !important;
        }

        /* Evita que el canvas WebGL componga encima del overlay de carga en algunos navegadores. */
        #viewer {
            pointer-events: auto;
            touch-action: none;
            width: 100%;
            height: 100%;
            min-height: 200px;
            cursor: grab;
            position: relative;
            z-index: 3;
        }

        #viewer canvas {
            position: relative;
            z-index: 3;
            display: block;
            pointer-events: auto !important;
            touch-action: none;
            cursor: grab;
        }

        .command-panel {
            display: flex;
            flex-direction: column;
            gap: 12px;
            min-height: 0;
            background: var(--panel-bg);
            color: var(--text);
            border-radius: var(--radius);
            padding: 14px 18px 18px;
            border: 1.5px solid var(--panel-border);
            box-shadow: 0 18px 40px rgba(2, 8, 23, 0.28), var(--card-inset);
            backdrop-filter: blur(12px);
            overflow-x: hidden;
            overflow-y: auto;
            max-height: calc(100vh - 120px);
            scrollbar-gutter: stable;
        }

        .command-panel .command-card {
            flex-shrink: 0;
            min-width: 0;
        }

        .command-panel-head {
            display: flex;
            flex-direction: column;
            gap: 8px;
        }

        .viewer-shell {
            position: relative;
            width: 100%;
            height: clamp(420px, 58vh, 760px);
            overflow: hidden;
            border-radius: var(--radius);
            border: 1.5px solid var(--panel-border);
            background: linear-gradient(165deg, rgba(16, 22, 42, 0.88), rgba(8, 12, 24, 0.78));
            box-shadow: 0 18px 40px rgba(2, 8, 23, 0.35), var(--card-inset);
        }

        .viewer-shell::before {
            content: 'Selecciona un proyecto y carga el BIM para comenzar';
            position: absolute;
            inset: 0;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 13px;
            color: rgba(248, 250, 252, 0.2);
            pointer-events: none;
            transition: opacity 0.4s ease;
            z-index: 2;
        }

        .viewer-shell.viewer-active::before,
        .viewer-shell.is-loading::before,
        .viewer-shell.has-model::before,
        .viewer-shell:has(#viewer canvas)::before {
            opacity: 0;
            visibility: hidden;
            pointer-events: none;
        }

        .viewer-hud {
            position: absolute;
            top: 10px;
            left: 10px;
            display: flex;
            align-items: center;
            gap: 6px;
            background: rgba(2, 3, 10, 0.72);
            backdrop-filter: blur(8px);
            border: 1px solid rgba(255, 255, 255, 0.08);
            border-radius: 8px;
            padding: 5px 10px;
            font-size: 11px;
            font-weight: 500;
            color: rgba(248, 250, 252, 0.6);
            pointer-events: none;
            opacity: 0;
            transition: opacity 0.3s ease;
            z-index: 12;
        }

        .viewer-hud.is-visible {
            opacity: 1;
        }

        .viewer-hud__sep {
            color: rgba(255, 255, 255, 0.2);
        }
        @media (min-width: 1200px) {
            .viewer-shell {
                height: clamp(620px, 68vh, 860px);
            }
        }

        .viewer-loader {
            position: absolute;
            inset: 0;
            display: flex;
            align-items: center;
            justify-content: center;
            background:
                radial-gradient(circle at 20% 20%, rgba(79,163,255,.24), transparent 45%),
                radial-gradient(circle at 80% 70%, rgba(246,168,104,.2), transparent 42%),
                rgba(0, 1, 21, 0.82);
            color: #fff;
            font-size: 14px;
            letter-spacing: 0.08em;
            text-transform: uppercase;
            z-index: 30;
            opacity: 0;
            pointer-events: none;
            transition: opacity 0.2s ease;
        }

        .viewer-loader.is-visible {
            opacity: 1;
            pointer-events: auto;
            visibility: visible;
        }

        .viewer-shell.is-loading #viewer,
        .viewer-shell.is-loading #viewer canvas {
            pointer-events: none !important;
            visibility: hidden;
        }

        .viewer-loader:not(.is-visible) {
            pointer-events: none !important;
            visibility: hidden;
        }

        .viewer-loader__panel {
            width: min(340px, 88vw);
            border: 1px solid rgba(255,255,255,.18);
            border-radius: 18px;
            background: rgba(4,9,33,.74);
            box-shadow: 0 24px 60px rgba(0,0,0,.42);
            padding: 18px;
            backdrop-filter: blur(8px);
            display: flex;
            flex-direction: column;
            align-items: center;
        }

        .viewer-loader__ring {
            display: none !important;
        }

        .viewer-loader__stage {
            font-size: 11px;
            letter-spacing: 0.08em;
            text-transform: uppercase;
            color: rgba(246, 168, 104, 0.7);
            margin-top: 6px;
            margin-bottom: 4px;
            width: 100%;
            text-align: center;
        }

        .viewer-loader .teleport-text {
            font-size: 11px;
            text-transform: uppercase;
            letter-spacing: .08em;
            display: flex;
            align-items: center;
            gap: 6px;
            justify-content: space-between;
            color: #e2e8f0;
            margin-bottom: 8px;
            font-weight: 700;
            width: 100%;
        }

        .viewer-loader .teleport-subtitle {
            text-transform: none;
            letter-spacing: .02em;
            font-size: 12px;
            color: rgba(226,232,240,.8);
            margin-bottom: 10px;
        }

        .viewer-loader .teleport-bar {
            margin-top: 12px;
            width: 220px;
            height: 8px;
            border-radius: 999px;
            background: rgba(255,255,255,0.2);
            overflow: hidden;
            border: 1px solid rgba(255,255,255,0.35);
        }

        .viewer-loader .teleport-progress {
            height: 100%;
            width: 0%;
            background: linear-gradient(120deg, var(--accent), var(--accent-2));
            transition: width 0.2s ease;
        }

        .viewer-info-card {
            position: absolute;
            left: 16px;
            bottom: 16px;
            background: rgba(0, 0, 0, 0.72);
            color: #fff;
            padding: 10px 12px;
            border-radius: 12px;
            font-size: 0.8rem;
            line-height: 1.4;
            max-width: 260px;
            box-shadow: 0 12px 24px rgba(0,0,0,0.3);
            opacity: 0;
            transform: translateY(8px);
            transition: opacity 0.2s ease, transform 0.2s ease;
            pointer-events: none;
            z-index: 12;
        }

        .viewer-info-card.is-visible {
            opacity: 1;
            transform: translateY(0);
        }

        .viewer-info-card .label {
            font-size: 0.7rem;
            text-transform: uppercase;
            letter-spacing: 0.08em;
            opacity: 0.75;
            margin-bottom: 4px;
        }

        .command-card {
            background:
                radial-gradient(circle at top right, rgba(102, 200, 255, 0.06), transparent 42%),
                radial-gradient(circle at bottom left, rgba(246, 168, 104, 0.05), transparent 40%),
                linear-gradient(170deg, rgba(255, 255, 255, 0.94), rgba(241, 245, 249, 0.9));
            border: 1px solid rgba(246, 168, 104, 0.22);
            border-radius: var(--radius-sm);
            padding: 18px;
            display: flex;
            flex-direction: column;
            gap: 14px;
            box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
        }

        .command-panel,
        .command-card,
        .command-panel label,
        .command-card label,
        .command-panel select,
        .command-panel input,
        .command-card select,
        .command-card input {
            font-family: 'Inter', sans-serif;
        }

        .command-panel select,
        .command-panel option,
        .command-panel input,
        .command-card select,
        .command-card option,
        .command-card input {
            color: #0B1022 !important;
        }

        .command-card .small,
        .status-text {
            color: rgba(0,0,0,0.60) !important;
        }

        .command-card h3 {
            margin: 0;
            font-family: 'Baloo 2', sans-serif;
            font-size: 1rem;
            color: #0B1022;
        }

        .command-panel-title {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 12px;
        }

        .command-panel-title h2 {
            margin: 0;
            font-family: 'Baloo 2', system-ui, sans-serif;
            font-size: 1.1rem;
            color: #fff;
        }

        .command-panel-title span {
            font-size: 0.75rem;
            text-transform: uppercase;
            letter-spacing: 0.15em;
            color: var(--muted);
            font-weight: 700;
        }

        .selection-meta {
            display: grid;
            gap: 8px;
        }

        .selection-row {
            display: flex;
            justify-content: space-between;
            gap: 12px;
            font-size: 0.85rem;
        }

        .selection-row span {
            color: rgba(0,0,0,0.55);
            font-weight: 600;
        }

        [data-section="selection-info"] .rum-mc-selection-body {
            display: flex;
            flex-direction: column;
            gap: 14px;
        }

        [data-section="selection-info"] .rum-mc-selection-toolbar {
            display: grid;
            gap: 12px;
        }

        [data-section="selection-info"] .rum-mc-selection-toolbar__chips {
            display: flex;
            flex-wrap: wrap;
            gap: 8px;
        }

        [data-section="selection-info"] .rum-mc-selection-section {
            padding: 12px 14px;
            border-radius: 12px;
            border: 1px solid rgba(42, 109, 176, 0.22);
            background: linear-gradient(165deg, rgba(255, 255, 255, 0.92), rgba(241, 245, 249, 0.88));
            box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);
        }

        [data-section="selection-info"] .rum-mc-selection-section__head {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 10px;
            margin-bottom: 10px;
        }

        [data-section="selection-info"] .rum-mc-selection-section__title {
            font-size: 0.72rem;
            font-weight: 700;
            letter-spacing: 0.06em;
            text-transform: uppercase;
            color: rgba(11, 16, 34, 0.62);
        }

        [data-section="selection-info"] .rum-mc-selection-section__badge {
            font-size: 0.78rem;
            font-weight: 700;
            font-variant-numeric: tabular-nums;
            padding: 3px 9px;
            border-radius: 999px;
            background: rgba(246, 168, 104, 0.18);
            color: #9a3412;
            border: 1px solid rgba(246, 168, 104, 0.35);
        }

        [data-section="selection-info"] .rum-mc-selection-section__grid {
            display: grid;
            gap: 10px;
        }

        @media (min-width: 520px) {
            [data-section="selection-info"] .rum-mc-selection-section__grid {
                grid-template-columns: minmax(140px, 0.45fr) minmax(0, 1fr);
                align-items: end;
            }
        }

        [data-section="selection-info"] .rum-mc-selection-field {
            display: grid;
            gap: 6px;
            min-width: 0;
        }

        [data-section="selection-info"] .rum-mc-selection-field__label {
            font-size: 0.7rem;
            font-weight: 700;
            letter-spacing: 0.05em;
            text-transform: uppercase;
            color: rgba(11, 16, 34, 0.5);
        }

        [data-section="selection-info"] .rum-mc-selection-field__control {
            width: 100%;
            padding: 8px 10px;
            border-radius: 10px;
            border: 1px solid rgba(128, 170, 215, 0.55);
            background: #fff;
            color: #0b1022;
            font-size: 0.85rem;
            box-sizing: border-box;
        }

        [data-section="selection-info"] .rum-mc-selection-field__range {
            width: 100%;
            accent-color: #f6a868;
            margin: 0;
        }

        [data-section="selection-info"] .rum-mc-selection-hint {
            margin: 0;
            padding: 10px 12px;
            border-radius: 10px;
            font-size: 0.82rem;
            line-height: 1.4;
            color: rgba(11, 16, 34, 0.55);
            background: rgba(42, 109, 176, 0.08);
            border: 1px dashed rgba(42, 109, 176, 0.28);
        }

        [data-section="selection-info"] .rum-mc-selection-hint[hidden] {
            display: none;
        }

        [data-section="selection-info"] .rum-mc-selection-details {
            display: grid;
            gap: 0;
            border-radius: 12px;
            border: 1px solid rgba(42, 109, 176, 0.2);
            background: #fff;
            overflow: hidden;
            box-shadow: 0 8px 22px rgba(2, 8, 23, 0.06);
        }

        [data-section="selection-info"] .rum-mc-selection-details:not(.has-selection) {
            opacity: 0.72;
        }

        [data-section="selection-info"] .rum-mc-selection-details__row {
            display: grid;
            grid-template-columns: minmax(108px, 34%) minmax(0, 1fr);
            gap: 10px 14px;
            align-items: start;
            padding: 10px 14px;
            border-bottom: 1px solid rgba(15, 23, 42, 0.06);
            font-size: 0.84rem;
        }

        [data-section="selection-info"] .rum-mc-selection-details__row:last-child {
            border-bottom: none;
        }

        [data-section="selection-info"] .rum-mc-selection-details__key {
            color: rgba(11, 16, 34, 0.52);
            font-weight: 600;
            font-size: 0.76rem;
            text-transform: uppercase;
            letter-spacing: 0.04em;
            line-height: 1.35;
        }

        [data-section="selection-info"] .rum-mc-selection-details__val {
            color: #0b1022;
            font-weight: 600;
            font-size: 0.88rem;
            line-height: 1.4;
            text-align: right;
            word-break: break-word;
        }

        [data-section="selection-info"] .rum-mc-selection-details__row--issue.has-flag .rum-mc-selection-details__val {
            color: #b91c1c;
            background: rgba(239, 68, 68, 0.1);
            padding: 2px 8px;
            border-radius: 6px;
        }

        .family-analytics {
            display: grid;
            grid-template-columns: 120px minmax(0, 1fr);
            gap: 12px;
            align-items: center;
        }

        .family-donut {
            width: 110px;
            height: 110px;
            border-radius: 50%;
            display: grid;
            place-items: center;
            background: conic-gradient(#2A6DB0 360deg, rgba(0,0,0,0.08) 0deg);
            position: relative;
        }

        .family-donut::after {
            content: "";
            width: 60px;
            height: 60px;
            border-radius: 50%;
            background: #fff;
            position: absolute;
            inset: 0;
            margin: auto;
        }

        .family-donut-center {
            position: relative;
            z-index: 1;
            font-size: 0.78rem;
            font-weight: 700;
            text-align: center;
            color: #0B1022;
            line-height: 1.2;
        }

        .family-summary {
            font-size: 0.82rem;
            color: rgba(0,0,0,0.75);
            margin-bottom: 6px;
        }

        .family-category-list {
            margin: 0;
            padding-left: 16px;
            max-height: 140px;
            overflow: auto;
            display: grid;
            gap: 4px;
            font-size: 0.77rem;
            color: rgba(0,0,0,0.75);
        }

        .family-model-categories {
            font-size: 0.76rem;
            color: rgba(0,0,0,0.68);
            margin-top: 8px;
            line-height: 1.35;
        }

        [data-section="bim-viewer"] .rum-viewer-widget--docked-right {
            width: 100%;
            max-width: 100%;
            min-height: 0;
        }

        [data-section="bim-viewer"] .rum-viewer-widget__body {
            min-height: 0;
        }

        [data-section="bim-viewer"] .viewer-shell {
            height: min(320px, 36vh);
            min-height: 220px;
            max-height: 420px;
        }

        @media (min-width: 1200px) {
            [data-section="bim-viewer"] .viewer-shell {
                height: min(380px, 42vh);
                max-height: 480px;
            }
        }

        .command-panel-actions {
            display: flex;
            gap: 8px;
            flex-wrap: wrap;
            margin-bottom: 0;
        }

        .command-panel-actions button {
            padding: 6px 12px;
            font-size: 0.78rem;
            border-radius: 10px;
        }

        .btn-edges {
            display: inline-flex;
            align-items: center;
            gap: 6px;
            font-size: 12px;
            letter-spacing: 0.04em;
        }

        .btn-edges.is-active {
            background: rgba(246, 168, 104, 0.2);
            color: #f6a868;
            border-color: rgba(246, 168, 104, 0.5);
        }

        .btn-topo.is-active {
            background: rgba(74, 74, 74, 0.18);
            color: #3f3f46;
            border-color: rgba(74, 74, 74, 0.45);
        }

        .btn-topo:disabled {
            opacity: 0.55;
            cursor: not-allowed;
        }

        .clash-row--low td:first-child {
            border-left: 3px solid #22c55e;
        }

        .clash-row--medium td:first-child {
            border-left: 3px solid #f59e0b;
        }

        .clash-row--high td:first-child {
            border-left: 3px solid #ef4444;
        }

        .command-panel-divider {
            height: 1px;
            background: rgba(255, 255, 255, 0.1);
            border: none;
            margin: 0;
        }

        .command-header {
            display: flex;
            align-items: center;
            gap: 10px;
            width: 100%;
            background: transparent;
            border: none;
            padding: 0;
            text-align: left;
            cursor: pointer;
            color: inherit;
            border-radius: 12px;
            box-shadow: none;
        }

        .command-header:focus-visible {
            outline: 2px solid rgba(42,109,176,0.55);
            outline-offset: 4px;
            border-radius: 12px;
        }

        .command-toggle {
            margin-left: auto;
            font-size: 1rem;
            color: rgba(0,0,0,0.5);
            transition: transform 0.2s ease;
        }

        .command-body {
            display: flex;
            flex-direction: column;
            gap: 14px;
        }

        .command-card.is-collapsed .command-body {
            display: none;
        }

        .command-card.is-collapsed .command-toggle {
            transform: rotate(-90deg);
        }

        .command-index {
            width: 28px;
            height: 28px;
            border-radius: 50%;
            background: rgba(42,109,176,0.12);
            border: 1px solid rgba(42,109,176,0.35);
            color: #2A6DB0;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            font-weight: 700;
            font-size: 0.85rem;
        }

        .command-form {
            display: grid;
            gap: 12px;
        }

        .command-form label:not(.inline-check) {
            font-size: 0.7rem;
            text-transform: uppercase;
            letter-spacing: 0.08em;
            color: rgba(0,0,0,0.55);
            font-weight: 700;
        }

        .command-form select,
        .command-form input:not([type="checkbox"]):not([type="radio"]) {
            padding: 8px 10px;
            border-radius: 10px;
            border: 1px solid rgba(128, 170, 215, 0.5);
            background: rgba(255, 255, 255, 0.72);
            color: #0B1022;
            font-size: 0.85rem;
            width: 100%;
            box-sizing: border-box;
        }

        .command-form select[multiple] {
            max-height: 10.5rem;
            min-height: 5.5rem;
            overflow-y: auto;
        }

        .command-form .inline-check {
            display: flex;
            align-items: center;
            gap: 8px;
            font-size: 0.85rem;
            font-weight: 600;
            color: rgba(0, 0, 0, 0.78);
            text-transform: none;
            letter-spacing: normal;
            cursor: pointer;
        }

        .command-form .inline-check input {
            width: auto;
            min-width: 0;
            padding: 0;
            flex-shrink: 0;
        }

        .command-form .select-actions {
            display: flex;
            flex-wrap: wrap;
            gap: 8px;
        }

        .command-form .status-text {
            display: block;
            max-width: 100%;
            line-height: 1.4;
        }


        .side-panel {
            background: rgba(10, 14, 28, 0.42);
            backdrop-filter: blur(20px);
            border-left: 1px solid var(--line);
            padding: 25px;
            overflow-y: auto;
        }

        .card {
            background:
                linear-gradient(180deg, rgba(248, 250, 252, 0.98), rgba(241, 245, 249, 0.95));
            border-radius: var(--radius-sm);
            padding: 18px;
            margin-bottom: 20px;
            border: 1.5px solid rgba(246, 168, 104, 0.28);
            color: #0f172a;
            box-shadow: 0 12px 36px rgba(2, 8, 23, 0.12), var(--card-inset);
        }
        .card h3 {
            margin: 0 0 15px 0;
            font-family: 'Baloo 2', system-ui, sans-serif;
            color: #0f172a;
            border-bottom: 1px solid rgba(15, 23, 42, 0.1);
            padding-bottom: 5px;
        }

        .control-row { margin-bottom: 15px; }
        .control-row label { display: block; font-size: 11px; text-transform: uppercase; opacity: 0.7; margin-bottom: 5px; font-weight: 600; }
        .control-row input[type="range"] { width: 100%; cursor: pointer; accent-color: var(--rum-btn); }

        .kv { display: flex; justify-content: space-between; margin-bottom: 6px; font-size: 12px; }
        .btn-rum { 
            background: #F1E1CF;
            color: #7A4A1C;
            border: 1px solid #E9B27F;
            padding: 9px 20px;
            border-radius: 18px;
            font-family: 'Baloo 2';
            font-weight: 700;
            cursor: pointer;
            box-shadow: none;
            transition: background-color .18s ease, border-color .18s ease, color .18s ease;
        }
        .btn-rum:hover:not(:disabled) {
            background: #EFD8C0;
            border-color: #E3A46A;
            color: #6E4118;
            transform: none;
            filter: none;
        }
        .btn-rum:disabled {
            opacity: .6;
            cursor: not-allowed;
            background: #F3E7DA;
            color: #A67D55;
            border-color: #E7C9AA;
        }

        .btn-ghost {
            background: rgba(0,0,0,0.04);
            border: 1px solid rgba(0,0,0,0.12);
            color: #0B1022;
            padding: 6px 12px;
            border-radius: 10px;
            font-family: 'Inter', sans-serif;
            font-size: 0.78rem;
            cursor: pointer;
        }

        .btn-rum.btn-secondary {
            background: #F4E7D9;
            color: #7A4A1C;
            border: 1px solid #E8BE94;
        }

        .topbar-actions {
            display: flex;
            gap: 10px;
            align-items: center;
        }

        .topbar-nav-btn {
            text-decoration: none;
            white-space: nowrap;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            padding: 8px 14px;
            font-size: 12px;
        }

        .project-filter {
            display: flex;
            gap: 8px;
            align-items: flex-end;
            padding: 6px 10px;
            border-radius: 12px;
            border: 1px solid var(--stroke);
            background: rgba(255, 255, 255, 0.06);
        }

        .project-filter label {
            display: block;
            font-size: 10px;
            text-transform: uppercase;
            letter-spacing: 0.08em;
            opacity: 0.7;
            margin-bottom: 4px;
        }

        .project-filter input,
        .project-filter select {
            padding: 6px 8px;
            border-radius: 8px;
            border: 1px solid var(--stroke);
            background: rgba(0, 0, 0, 0.4);
            color: #fff;
            font-size: 12px;
            min-width: 120px;
        }

        .project-filter .status {
            font-size: 11px;
            opacity: 0.7;
            min-width: 160px;
        }

        .context-menu {
            position: absolute;
            background: var(--panel-bg);
            border: 1.5px solid var(--panel-border);
            border-radius: var(--radius-sm);
            padding: 12px;
            display: none;
            z-index: 999;
            box-shadow: 0 18px 40px rgba(2, 8, 23, 0.45), var(--card-inset);
            backdrop-filter: blur(12px);
            min-width: 180px;
            color: var(--text);
        }

        .clash-table {
            width: 100%;
            border-collapse: collapse;
            margin-top: 12px;
            font-size: 12px;
        }

        .clash-table th,
        .clash-table td {
            border-bottom: 1px solid var(--stroke);
            padding: 8px 6px;
            text-align: left;
        }

        .clash-table th {
            text-transform: uppercase;
            letter-spacing: 0.05em;
            font-size: 10px;
            opacity: 0.7;
        }

        .clash-table tbody tr {
            background: rgba(246, 248, 252, 0.9);
        }

        .clash-table tbody tr + tr {
            margin-top: 6px;
        }

        .clash-table .highlight {
            color: #ff6b6b;
            font-weight: 700;
        }

        .table-wrapper {
            max-height: 240px;
            overflow: auto;
            border: 1px solid rgba(42, 109, 176, 0.2);
            border-radius: 12px;
            background: #ffffff;
        }

        .report-modal {
            position: fixed;
            inset: 0;
            background: rgba(0, 0, 0, 0.6);
            display: none;
            align-items: center;
            justify-content: center;
            z-index: 9999;
            padding: 24px;
        }

        .report-modal.active {
            display: flex;
        }

        .report-card {
            background: #ffffff;
            border-radius: 18px;
            padding: 24px;
            width: min(900px, 100%);
            max-height: 90vh;
            overflow: auto;
            box-shadow: 0 25px 60px rgba(0, 0, 0, 0.35);
            color: #0B1022;
        }

        .report-brand-row {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 16px;
            padding-bottom: 14px;
            margin-bottom: 12px;
            border-bottom: 1px solid rgba(15, 23, 42, 0.12);
        }

        .report-brand-logo {
            display: block;
            object-fit: contain;
            max-height: 56px;
            width: auto;
        }

        .report-brand-logo--rum {
            max-height: 52px;
        }

        .report-brand-spacer {
            flex: 1;
        }

        .section-title {
            font-size: 12px;
            text-transform: uppercase;
            letter-spacing: 0.08em;
            opacity: 0.75;
            margin-bottom: 8px;
        }

        .rum-mc-clash-setup-note {
            text-transform: none;
            letter-spacing: 0;
            font-size: 11px;
            font-weight: 500;
            opacity: 0.85;
        }

        .function-selector {
            display: grid;
            gap: 10px;
        }

        .function-option {
            display: flex;
            gap: 10px;
            align-items: center;
            padding: 12px 14px;
            border-radius: 12px;
            border: 1px solid rgba(128, 170, 215, 0.45);
            background: linear-gradient(160deg, rgba(245,250,255,0.95), rgba(228,241,255,0.9));
            cursor: pointer;
            transition: transform 0.2s ease, box-shadow 0.2s ease;
        }

        .function-option:hover {
            transform: translateY(-2px);
            box-shadow: 0 10px 18px rgba(42, 109, 176, 0.15);
        }

        .function-option input {
            accent-color: var(--rum-btn);
        }

        .function-panel {
            display: none;
        }

        .function-panel.active {
            display: block;
        }

        .clash-grid,
        .compare-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
            gap: 10px;
        }

        .clash-grid select,
        .compare-grid select {
            width: 100%;
            padding: 10px 12px;
            border-radius: 12px;
            border: 1px solid rgba(42, 109, 176, 0.35);
            background: #ffffff;
            color: #0B1022;
            box-shadow: 0 10px 18px rgba(42, 109, 176, 0.1);
        }

        .clash-grid select:focus,
        .compare-grid select:focus {
            outline: 2px solid rgba(246, 168, 104, 0.6);
            border-color: rgba(246, 168, 104, 0.8);
        }

        .select-actions {
            display: flex;
            gap: 8px;
            margin-top: 8px;
            flex-wrap: wrap;
        }

        .select-actions button {
            font-size: 11px;
            padding: 6px 10px;
            border-radius: 999px;
        }

        .select-actions input[type="number"] {
            padding: 6px 10px;
            border-radius: 999px;
            border: 1px solid rgba(42, 109, 176, 0.35);
            min-width: 120px;
        }

        .action-row {
            display: flex;
            flex-wrap: wrap;
            gap: 8px;
            margin-top: 10px;
        }

        .action-row--publish {
            border-top: 1px solid rgba(255, 255, 255, 0.12);
            padding-top: 8px;
            margin-top: 8px;
        }

        .rum-mc-clash-actions {
            gap: 6px;
            margin-top: 8px;
        }

        .rum-mc-clash-actions .btn-rum {
            padding: 5px 11px;
            font-size: 0.72rem;
            border-radius: 12px;
            font-weight: 600;
            line-height: 1.25;
            letter-spacing: 0.01em;
        }

        .rum-mc-clash-actions .btn-rum.btn-rum--compact {
            padding: 3px 7px;
            font-size: 0.62rem;
            border-radius: 10px;
            flex: 0 0 auto;
        }

        .rum-mc-post-publish-cta {
            display: none;
            margin-top: 8px;
            text-decoration: none;
        }

        .status-text {
            font-size: 12px;
            opacity: 0.75;
            margin-top: 6px;
            color: #0B1022;
        }

        .clash-table {
            width: 100%;
            border-collapse: collapse;
            margin-top: 12px;
            font-size: 12px;
        }

        .clash-table th,
        .clash-table td {
            border-bottom: 1px solid var(--stroke);
            padding: 8px 6px;
            text-align: left;
        }

        .clash-table th {
            text-transform: uppercase;
            letter-spacing: 0.05em;
            font-size: 10px;
            opacity: 0.7;
        }

        .clash-table tbody tr {
            background: rgba(246, 248, 252, 0.9);
        }

        .clash-table tbody tr + tr {
            margin-top: 6px;
        }

        .clash-table .highlight {
            color: #ff6b6b;
            font-weight: 700;
        }

        .table-wrapper {
            max-height: 240px;
            overflow: auto;
            border: 1px solid rgba(42, 109, 176, 0.2);
            border-radius: 12px;
            background: #ffffff;
        }

        .report-modal {
            position: fixed;
            inset: 0;
            background: rgba(0, 0, 0, 0.6);
            display: none;
            align-items: center;
            justify-content: center;
            z-index: 9999;
            padding: 24px;
        }

        .report-modal.active {
            display: flex;
        }

        .report-card {
            background: #ffffff;
            border-radius: 18px;
            padding: 24px;
            width: min(900px, 100%);
            max-height: 90vh;
            overflow: auto;
            box-shadow: 0 25px 60px rgba(0, 0, 0, 0.35);
            color: #0B1022;
        }

        .report-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            gap: 12px;
            border-bottom: 1px solid rgba(0, 0, 0, 0.1);
            padding-bottom: 12px;
            margin-bottom: 16px;
        }

        .report-title {
            font-family: 'Baloo 2';
            font-size: 20px;
            color: var(--rum-primary);
            margin: 0;
        }

        .report-meta {
            font-size: 12px;
            opacity: 0.7;
            display: grid;
            gap: 4px;
        }

        .report-actions {
            display: flex;
            gap: 8px;
            flex-wrap: wrap;
        }

        .report-actions button {
            border-radius: 999px;
        }

        .report-table {
            width: 100%;
            border-collapse: collapse;
            margin-top: 12px;
        }

        .report-table th,
        .report-table td {
            border-bottom: 1px solid rgba(0, 0, 0, 0.08);
            padding: 10px 8px;
            text-align: left;
            font-size: 12px;
        }

        .report-table th {
            text-transform: uppercase;
            letter-spacing: 0.05em;
            font-size: 10px;
            opacity: 0.7;
        }

        @media print {
            @page {
                size: A4 landscape;
                margin: 12mm;
            }
            body * {
                visibility: hidden;
            }
            .report-modal.active,
            .report-modal.active * {
                visibility: visible;
            }
            .report-modal {
                position: absolute;
                inset: 0;
                left: 0;
                top: 0;
                background: #fff !important;
                padding: 0;
                display: block !important;
                overflow: visible !important;
            }
            .report-card {
                box-shadow: none;
                max-height: none;
                width: 100%;
                border-radius: 0;
                overflow: visible !important;
                color: #000 !important;
                background: #fff !important;
            }
            .report-brand-row {
                border-bottom: 1px solid #ccc;
            }
            .report-table {
                page-break-inside: auto;
            }
            .report-table tr {
                page-break-inside: avoid;
                page-break-after: auto;
            }
            .report-actions {
                display: none !important;
            }
        }

        .topbar-context {
            display: flex;
            flex-wrap: wrap;
            gap: 8px;
            align-items: center;
            justify-content: flex-end;
        }

        .topbar-pill {
            display: inline-flex;
            align-items: center;
            padding: 6px 12px;
            border-radius: 999px;
            border: 1px solid rgba(255, 255, 255, 0.2);
            font-size: 12px;
            font-weight: 700;
            color: #f8fafc;
            background: rgba(8, 12, 28, 0.35);
            max-width: min(220px, 28vw);
            overflow: hidden;
            text-overflow: ellipsis;
            white-space: nowrap;
        }

        .topbar-pill--muted {
            font-weight: 600;
            color: rgba(248, 250, 252, 0.82);
            border-color: rgba(255, 255, 255, 0.12);
        }

        /* Tabla de interferencias: hover ligero + selección (sin sombras pesadas = menos repintes) */
        .clash-table tbody tr {
            cursor: pointer;
            transition: background-color 0.1s ease;
        }

        .clash-table tbody tr:hover {
            background: rgba(254, 242, 242, 0.92) !important;
        }

        .clash-table tbody tr.is-selected {
            background: rgba(254, 226, 226, 0.96) !important;
            box-shadow: inset 4px 0 0 #dc2626;
        }

        .clash-table tbody tr.is-selected:hover {
            background: rgba(252, 165, 165, 0.35) !important;
        }

        .clash-table tbody tr input,
        .clash-table tbody tr select,
        .clash-table tbody tr textarea {
            cursor: default;
        }

        #clashTableWrapper.rum-mc-clash-dragging,
        #clashTableWrapper.rum-mc-clash-dragging .clash-table {
            user-select: none;
            -webkit-user-select: none;
            cursor: crosshair;
        }

        #clashTableWrapper.rum-mc-clash-dragging .clash-table tbody tr.is-selected {
            background: rgba(252, 165, 165, 0.38) !important;
        }

        .clash-col-pick,
        .clash-row-pick {
            width: 28px;
            min-width: 28px;
            padding: 6px 4px !important;
            text-align: center;
            vertical-align: middle;
        }

        .clash-row-pick-indicator {
            display: inline-block;
            width: 14px;
            height: 14px;
            border-radius: 50%;
            border: 2px solid rgba(100, 116, 139, 0.55);
            background: #fff;
            box-sizing: border-box;
            vertical-align: middle;
        }

        .clash-row-pick-indicator.is-on {
            border-color: #dc2626;
            background: #dc2626;
            box-shadow: 0 0 0 2px rgba(220, 38, 38, 0.28);
        }

        .clash-table tbody tr.is-selected .clash-row-pick-indicator {
            border-color: #dc2626;
            background: #dc2626;
        }

        #clashTableWrapper:focus {
            outline: 2px solid rgba(220, 38, 38, 0.42);
            outline-offset: 2px;
        }

        .rum-mc-clash-pick-disabled,
        .rum-mc-clash-pick-disabled canvas {
            cursor: grab !important;
        }
