* {
    box-sizing: border-box;
}


html,
body {
    width: 100%;
    height: 100%;

    margin: 0;
    padding: 0;

    overflow: hidden;

    font-family:
        Inter,
        Arial,
        sans-serif;

    color: #151515;
}


body {
    background: #e9e9e9;
}


/* =====================================================
   VISOR
===================================================== */

.viewer3d {
    position: fixed;

    inset: 0;

    width: 100vw;
    height: 100vh;

    overflow: hidden;

    background: #e9e9e9;
}


.viewer3d canvas {
    display: block;

    width: 100%;
    height: 100%;
}


/* =====================================================
   PANEL INFORMACIÓN
===================================================== */

.info-panel {
    position: fixed;

    z-index: 100;

    top: 20px;
    right: 20px;

    width: 286px;

    padding: 19px;

    background:
        rgba(
            255,
            255,
            255,
            .96
        );

    border:
        1px solid
        rgba(
            0,
            0,
            0,
            .06
        );

    border-radius: 15px;

    box-shadow:
        0 15px 45px
        rgba(
            0,
            0,
            0,
            .12
        );

    backdrop-filter:
        blur(14px);

    -webkit-backdrop-filter:
        blur(14px);

    transition:
        opacity .2s ease,
        transform .2s ease;
}


.info-panel.hidden {
    opacity: 0;

    transform:
        translateY(-8px)
        scale(.97);

    pointer-events:
        none;
}


/* =====================================================
   PANEL HEADER
===================================================== */

.panel-brand {
    margin-bottom: 4px;

    font-size: 9px;

    font-weight: 700;

    letter-spacing: .09em;

    color: #555;
}


.info-panel h1 {
    margin: 0;

    font-size: 21px;

    line-height: 1.1;

    font-weight: 700;

    letter-spacing: -.03em;
}


.info-panel > p {
    margin:
        8px 0 18px;

    color: #777;

    font-size: 11px;

    line-height: 1.5;
}


/* =====================================================
   MINIMIZAR
===================================================== */

.panel-toggle {
    position: absolute;

    top: 10px;
    right: 10px;

    width: 30px;
    height: 30px;

    padding: 0;

    border: 0;

    border-radius: 50%;

    background: #f1f1f1;

    color: #555;

    font-size: 18px;

    line-height: 30px;

    cursor: pointer;
}


.panel-toggle:hover {
    background: #e7e7e7;
}


/* =====================================================
   RESTAURAR
===================================================== */

.show-panel {
    position: fixed;

    z-index: 101;

    top: 20px;
    right: 20px;

    width: 38px;
    height: 38px;

    padding: 0;

    border: 0;

    border-radius: 12px;

    background:
        rgba(
            255,
            255,
            255,
            .96
        );

    color: #222;

    font-size: 14px;

    font-weight: 700;

    box-shadow:
        0 10px 30px
        rgba(
            0,
            0,
            0,
            .12
        );

    opacity: 0;

    transform:
        scale(.8);

    pointer-events:
        none;

    transition: .2s ease;
}


.show-panel.visible {
    opacity: 1;

    transform:
        scale(1);

    pointer-events:
        auto;
}


/* =====================================================
   DIMENSIONES
===================================================== */

.dimensions {
    display: flex;

    flex-direction: column;

    gap: 3px;

    padding:
        13px 0;

    border-top:
        1px solid #ededed;

    border-bottom:
        1px solid #ededed;

    font-size: 10px;

    color: #555;
}


.dimensions div {
    display: flex;

    justify-content:
        space-between;

    gap: 12px;
}


.dimensions strong {
    color: #171717;

    font-weight: 700;
}


/* =====================================================
   ELEMENTO SELECCIONADO
===================================================== */

.selected-element {
    padding-top: 14px;
}


.selected-element[hidden] {
    display:
        none !important;
}


.section-title {
    margin-bottom: 8px;

    font-size: 9px;

    font-weight: 700;

    letter-spacing: .08em;

    color: #777;
}


.selected-element h2 {
    margin:
        0 0 4px;

    font-size: 15px;

    line-height: 1.2;
}


#selectedShortTitle {
    margin-bottom: 7px;

    font-size: 10px;

    color: #777;
}


#selectedDescription {
    margin: 0;

    font-size: 10px;

    line-height: 1.45;

    color: #555;
}


/* =====================================================
   LISTA HOTSPOTS
===================================================== */

.points-section {
    margin-top: 17px;

    max-height: 48vh;

    overflow-y: auto;

    scrollbar-width: thin;

    scrollbar-color:
        #d4d4d4
        transparent;
}


.points-section[hidden] {
    display:
        none !important;
}


#pointsList {
    display: flex;

    flex-direction: column;

    gap: 5px;
}


.viewer-point-item {
    width: 100%;

    display: grid;

    grid-template-columns:
        25px
        1fr
        12px;

    align-items: center;

    gap: 8px;

    padding:
        7px 6px;

    border: 0;

    border-radius: 7px;

    background:
        transparent;

    text-align: left;

    color: #222;

    cursor: pointer;
}


.viewer-point-item:hover {
    background: #f3f3f3;
}


.viewer-point-item.is-selected {
    background: #f0f0f0;

    box-shadow:
        inset 3px 0 0 #111;
}


.viewer-point-item.is-selected .viewer-point-number {
    background: #111;

    transform: scale(1.06);
}


.viewer-point-item.is-selected .viewer-point-text strong {
    color: #111;
}


.viewer-point-state {
    width: 22px;
    height: 22px;

    display: flex;

    align-items: center;
    justify-content: center;

    border-radius: 50%;

    color: transparent;

    font-size: 11px;

    font-weight: 800;

    transition:
        background .18s ease,
        color .18s ease,
        transform .18s ease;
}


.viewer-point-item.is-selected .viewer-point-state {
    background: #111;

    color: #fff;

    transform: scale(1);
}


.viewer-point-number {
    width: 22px;
    height: 22px;

    display: flex;

    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background: #111;

    color: #fff;

    font-size: 9px;

    font-weight: 700;
}


.viewer-point-text {
    min-width: 0;

    display: flex;

    flex-direction: column;

    gap: 2px;
}


.viewer-point-text strong {
    font-size: 10px;

    white-space: nowrap;

    overflow: hidden;

    text-overflow: ellipsis;
}


.viewer-point-text small {
    font-size: 9px;

    color: #888;

    white-space: nowrap;

    overflow: hidden;

    text-overflow: ellipsis;
}


.viewer-point-arrow {
    color: #aaa;

    font-size: 16px;
}


/* =====================================================
   HOTSPOTS 3D
===================================================== */

.viewer-hotspot-label {
    display: none !important;

    pointer-events:
        none;

    white-space:
        nowrap;

    padding:
        7px 11px;

    border-radius:
        9px;

    background:
        rgba(
            18,
            18,
            18,
            .94
        );

    color: #fff;

    font-size: 11px;

    font-weight: 600;

    box-shadow:
        0 7px 22px
        rgba(
            0,
            0,
            0,
            .20
        );
}


/* =====================================================
   POPUP HOTSPOT
===================================================== */

.hotspot-popup {
    display: none !important;

    position: fixed;

    z-index: 1000;

    width: 275px;

    display: flex;

    gap: 11px;

    padding:
        13px 14px;

    background:
        rgba(
            255,
            255,
            255,
            .97
        );

    border:
        1px solid
        rgba(
            0,
            0,
            0,
            .07
        );

    border-radius:
        13px;

    box-shadow:
        0 18px 50px
        rgba(
            0,
            0,
            0,
            .18
        );

    backdrop-filter:
        blur(12px);

    -webkit-backdrop-filter:
        blur(12px);

    opacity: 0;

    transform:
        translateY(8px)
        scale(.97);

    pointer-events:
        none;

    transition:
        opacity .18s ease,
        transform .18s ease;
}


.hotspot-popup.visible {
    opacity: 1;

    transform:
        translateY(0)
        scale(1);

    pointer-events:
        auto;
}


.hotspot-popup-number {
    width: 28px;
    height: 28px;

    flex:
        0 0 28px;

    display: flex;

    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background: #111;

    color: #fff;

    font-size: 11px;

    font-weight: 700;
}


.hotspot-popup-content {
    min-width: 0;

    padding-right:
        10px;
}


.hotspot-popup-title {
    margin-bottom: 2px;

    font-size: 14px;

    font-weight: 700;

    color: #111;
}


.hotspot-popup-short {
    margin-bottom: 6px;

    font-size: 10px;

    color: #777;
}


.hotspot-popup-description {
    font-size: 11px;

    line-height: 1.45;

    color: #444;
}


.hotspot-popup-close {
    position: absolute;

    top: 7px;
    right: 7px;

    width: 22px;
    height: 22px;

    padding: 0;

    border: 0;

    border-radius: 50%;

    background: #f0f0f0;

    color: #555;

    font-size: 15px;

    line-height: 22px;

    cursor: pointer;
}


.hotspot-popup-close:hover {
    background: #e4e4e4;
}


/* =====================================================
   CONTROLES
===================================================== */

.viewer-controls {
    position: fixed;

    z-index: 200;

    left: 50%;
    bottom: 17px;

    transform:
        translateX(-50%);

    display: flex;

    align-items: center;

    gap: 2px;

    padding:
        6px 8px;

    background:
        rgba(
            22,
            22,
            22,
            .94
        );

    border-radius:
        12px;

    box-shadow:
        0 10px 35px
        rgba(
            0,
            0,
            0,
            .22
        );

    backdrop-filter:
        blur(12px);

    -webkit-backdrop-filter:
        blur(12px);
}


.viewer-controls button {
    display: flex;

    align-items: center;

    gap: 6px;

    padding:
        7px 10px;

    border: 0;

    border-radius: 7px;

    background:
        transparent;

    color: #fff;

    font-size: 10px;

    cursor: pointer;

    opacity: .85;

    transition:
        background .15s ease,
        opacity .15s ease;
}


.viewer-controls button:hover {
    background:
        rgba(
            255,
            255,
            255,
            .10
        );

    opacity: 1;
}


.viewer-controls button span {
    font-size: 9px;
}


.viewer-controls button:not(:last-child)::after {
    content: "";

    width: 1px;
    height: 15px;

    margin-left: 5px;

    background:
        rgba(
            255,
            255,
            255,
            .14
        );
}


/* =====================================================
   PANEL DE MEDICIÓN ACTIVA
===================================================== */

.measurement-panel {
    position: fixed;

    z-index: 500;

    left: 50%;
    bottom: 82px;

    transform:
        translateX(-50%)
        translateY(12px);

    width:
        min(
            320px,
            calc(100vw - 30px)
        );

    padding: 16px;

    border:
        1px solid
        rgba(
            255,
            255,
            255,
            .82
        );

    border-radius: 14px;

    background:
        rgba(
            255,
            255,
            255,
            .96
        );

    box-shadow:
        0 18px 55px
        rgba(
            0,
            0,
            0,
            .20
        );

    backdrop-filter:
        blur(14px);

    -webkit-backdrop-filter:
        blur(14px);

    opacity: 0;

    visibility:
        hidden;

    pointer-events:
        none;

    transition:
        opacity .18s ease,
        transform .18s ease,
        visibility .18s ease;
}


.measurement-panel.visible {
    opacity: 1;

    visibility:
        visible;

    pointer-events:
        auto;

    transform:
        translateX(-50%)
        translateY(0);
}


.measurement-panel-header {
    display: flex;

    align-items:
        flex-start;

    justify-content:
        space-between;

    gap: 12px;
}


.measurement-panel-header small {
    display: block;

    margin-bottom: 4px;

    font-size: 9px;

    font-weight: 800;

    letter-spacing: .14em;

    color: #858585;
}


.measurement-panel-header strong {
    display: block;

    font-size: 25px;

    line-height: 1;

    color: #111;
}


.measurement-panel-header button {
    width: 26px;
    height: 26px;

    padding: 0;

    border: 0;

    border-radius: 50%;

    background: #eeeeee;

    color: #555;

    font-size: 17px;

    cursor: pointer;
}


.measurement-panel-header button:hover {
    background: #e2e2e2;
}


.measurement-panel-info {
    margin-top: 13px;

    padding-top: 12px;

    border-top:
        1px solid #e8e8e8;
}


.measurement-panel-info span {
    display: block;

    font-size: 11px;

    line-height: 1.4;

    color: #666;
}


/* =====================================================
   ADMINISTRADOR DE MEDICIONES
===================================================== */

.measurement-manager {
    position: fixed;

    z-index: 600;

    left: 20px;
    bottom: 78px;

    width: 285px;

    padding: 15px;

    background:
        rgba(
            255,
            255,
            255,
            .97
        );

    border:
        1px solid
        rgba(
            0,
            0,
            0,
            .07
        );

    border-radius:
        14px;

    box-shadow:
        0 18px 55px
        rgba(
            0,
            0,
            0,
            .18
        );

    backdrop-filter:
        blur(14px);

    -webkit-backdrop-filter:
        blur(14px);

    opacity: 0;

    visibility:
        hidden;

    pointer-events:
        none;

    transform:
        translateY(10px)
        scale(.97);

    transition:
        opacity .18s ease,
        visibility .18s ease,
        transform .18s ease;
}


.measurement-manager.visible {
    opacity: 1;

    visibility:
        visible;

    pointer-events:
        auto;

    transform:
        translateY(0)
        scale(1);
}


.measurement-manager-header {
    padding-bottom:
        11px;

    border-bottom:
        1px solid #ededed;
}


.measurement-manager-header small {
    display: block;

    margin-bottom: 3px;

    font-size: 9px;

    font-weight: 800;

    letter-spacing: .14em;

    color: #858585;
}


.measurement-manager-header strong {
    display: block;

    font-size: 13px;

    color: #171717;
}


/* =====================================================
   LISTA MEDICIONES
===================================================== */

.measurement-list {
    display: flex;

    flex-direction:
        column;

    gap: 5px;

    max-height:
        220px;

    margin-top: 10px;

    overflow-y: auto;
}


.measurement-item {
    display: flex;

    align-items:
        center;

    justify-content:
        space-between;

    gap: 10px;

    padding:
        8px;

    border:
        1px solid #eeeeee;

    border-radius:
        9px;

    background:
        #fafafa;
}


.measurement-item-info {
    min-width: 0;

    display: flex;

    align-items:
        center;

    gap: 8px;
}


.measurement-item-number {
    width: 25px;
    height: 25px;

    flex:
        0 0 25px;

    display: flex;

    align-items:
        center;

    justify-content:
        center;

    border-radius:
        7px;

    background:
        #151515;

    color:
        #fff;

    font-size:
        9px;

    font-weight:
        700;
}


.measurement-item-title {
    font-size:
        10px;

    font-weight:
        700;

    color:
        #222;
}


.measurement-item-distance {
    display: block;

    margin-top:
        2px;

    font-size:
        10px;

    color:
        #777;
}


.measurement-item-delete {
    width: 25px;
    height: 25px;

    flex:
        0 0 25px;

    padding: 0;

    border: 0;

    border-radius:
        50%;

    background:
        #eeeeee;

    color:
        #666;

    font-size:
        16px;

    line-height:
        25px;

    cursor: pointer;
}


.measurement-item-delete:hover {
    background:
        #dedede;

    color:
        #111;
}


.measurement-delete-all {
    width: 100%;

    margin-top:
        10px;

    padding:
        9px 12px;

    border: 0;

    border-radius:
        8px;

    background:
        #151515;

    color:
        #fff;

    font-size:
        10px;

    font-weight:
        600;

    cursor:
        pointer;
}


.measurement-delete-all:hover {
    background:
        #303030;
}


/* =====================================================
   ETIQUETA DE MEDICIÓN
===================================================== */

.measurement-label {
    min-width:
        64px;

    padding:
        5px 8px;

    border-radius:
        7px;

    background:
        rgba(
            20,
            20,
            20,
            .94
        );

    color:
        #fff;

    font-size:
        10px;

    font-weight:
        700;

    text-align:
        center;

    white-space:
        nowrap;

    box-shadow:
        0 6px 20px
        rgba(
            0,
            0,
            0,
            .20
        );

    transform:
        translate(
            -50%,
            -50%
        );
}


/* =====================================================
   AYUDA / GUÍA DE CONTROLES
===================================================== */

.viewer-help {
    position: fixed;
    inset: 0;
    z-index: 1000;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 24px;

    background: rgba(12, 14, 18, .52);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);

    opacity: 0;
    visibility: hidden;
    pointer-events: none;

    transition:
        opacity 220ms ease,
        visibility 220ms ease;
}

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

.viewer-help-card {
    position: relative;

    width: min(940px, 100%);
    max-height: calc(100vh - 48px);
    overflow: hidden;

    display: flex;
    flex-direction: column;

    padding: 26px 32px 20px;

    border-radius: 22px;
    background: #ffffff;
    box-shadow: 0 30px 90px rgba(0, 0, 0, .35);

    transform: translateY(14px) scale(.98);
    transition: transform 220ms ease;
}

.viewer-help.visible .viewer-help-card {
    transform: translateY(0) scale(1);
}

.viewer-help-close {
    position: absolute;
    top: 16px;
    right: 16px;

    width: 38px;
    height: 38px;
    padding: 0;

    border: 0;
    border-radius: 50%;

    background: #eeeeee;
    color: #333;

    font-size: 26px;
    line-height: 1;
    cursor: pointer;

    transition: background 150ms ease;
}

.viewer-help-close:hover {
    background: #dddddd;
}

.viewer-help-kicker {
    margin-bottom: 8px;

    font-size: 12px;
    font-weight: 800;
    letter-spacing: .16em;
    color: #6b7078;
}

.viewer-help-card h2 {
    margin: 0;

    font-size: 32px;
    line-height: 1.1;
    letter-spacing: -.01em;
    color: #111;
}

.viewer-help-intro {
    max-width: 640px;
    margin: 8px 0 14px;

    font-size: 16px;
    line-height: 1.55;
    color: #444;
}

.viewer-help-intro b {
    color: #111;
}

/* ---------- secciones ---------- */

.viewer-help-header {
    flex: none;
}

.viewer-help-body {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    padding-right: 4px;

    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.help-section {
    padding: 12px 20px 4px;

    border: 1px solid #e4e4e4;
    border-radius: 16px;
    background: #fafafa;
}

.help-section-wide {
    grid-column: 1 / -1;
}

.help-section h3 {
    display: flex;
    align-items: center;
    gap: 10px;

    margin: 0 0 6px;

    font-size: 19px;
    font-weight: 800;
    color: #111;
}

.help-step {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 26px;
    height: 26px;

    border-radius: 50%;
    background: #111;
    color: #fff;

    font-size: 14px;
    font-weight: 800;
}

.help-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.help-list-cols {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 28px;
}

.help-row {
    display: flex;
    align-items: center;
    gap: 16px;

    padding: 8px 0;
    border-top: 1px solid #ececec;
}

.help-row:first-child {
    border-top: 0;
}

.help-list-cols .help-row:nth-child(2) {
    border-top: 0;
}

.help-visual {
    flex: 0 0 176px;

    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    gap: 8px;

    min-height: 44px;
}

.help-text strong {
    display: block;
    margin-bottom: 3px;

    font-size: 16px;
    font-weight: 700;
    line-height: 1.25;
    color: #111;
}

.help-text > span {
    display: block;

    font-size: 14.5px;
    line-height: 1.45;
    color: #555;
}

/* ---------- teclas, mouse y etiquetas ---------- */

.help-keys {
    display: inline-flex;
    flex-wrap: nowrap;
    gap: 5px;
}

.viewer-help kbd {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 38px;
    height: 38px;
    padding: 0 8px;

    border: 1px solid #b9b9b9;
    border-bottom-width: 3px;
    border-radius: 9px;
    background: #fff;
    box-shadow: 0 1px 0 rgba(0, 0, 0, .06);

    font-family: inherit;
    font-size: 16px;
    font-weight: 800;
    color: #111;
}

.viewer-help kbd.wide {
    min-width: 62px;
}

.viewer-help kbd.small {
    min-width: 28px;
    height: 26px;
    padding: 0 6px;

    border-bottom-width: 2px;
    border-radius: 6px;

    font-size: 13px;
    vertical-align: middle;
}

.help-plus {
    font-style: normal;
    font-size: 18px;
    font-weight: 700;
    color: #8a8f97;
}

.help-mouse {
    width: 30px;
    height: 44px;
    flex: none;
}

.help-drag {
    padding: 5px 10px;

    border-radius: 999px;
    background: #111;
    color: #fff;

    font-size: 13px;
    font-weight: 700;
}

.help-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 34px;
    height: 34px;
    padding: 0 10px;

    border-radius: 999px;
    background: #111;
    color: #fff;

    font-size: 14px;
    font-weight: 800;
}

.help-chip-wide {
    border-radius: 10px;
    white-space: nowrap;
}

/* ---------- pie ---------- */

.viewer-help-footer {
    display: flex;
    align-items: center;
    gap: 18px;
    flex-wrap: wrap;

    flex: none;
    margin-top: 12px;
    padding-top: 14px;
    border-top: 1px solid #e8e8e8;
}

.viewer-help-start {
    padding: 15px 28px;

    border: 0;
    border-radius: 12px;
    background: #111;
    color: #fff;

    font-family: inherit;
    font-size: 16px;
    font-weight: 800;
    cursor: pointer;

    transition: background 150ms ease, transform 150ms ease;
}

.viewer-help-start:hover {
    background: #2b2b2b;
    transform: translateY(-1px);
}

.viewer-help-hint {
    font-size: 14px;
    color: #666;
}

.viewer-help-close:focus-visible,
.viewer-help-start:focus-visible {
    outline: 3px solid #4da3ff;
    outline-offset: 2px;
}

/* ---------- táctil: se ocultan los atajos de teclado ---------- */

.help-touch-only {
    display: none !important;
}

@media (pointer: coarse) {

    .help-desktop-only {
        display: none !important;
    }

    .help-touch-only {
        display: block !important;
    }

    .help-row.help-touch-only {
        display: flex !important;
    }
}

/* ---------- pantallas medianas y celulares ---------- */

@media (max-width: 760px) {

    .viewer-help {
        padding: 12px;
    }

    .viewer-help-card {
        max-height: calc(100vh - 24px);
        padding: 26px 18px 20px;
        border-radius: 18px;
    }

    .viewer-help-card h2 {
        padding-right: 40px;
        font-size: 25px;
    }

    .viewer-help-intro {
        font-size: 15px;
    }

    .viewer-help-body,
    .help-list-cols {
        grid-template-columns: 1fr;
    }

    .help-section-wide {
        grid-column: auto;
    }

    .help-list-cols .help-row:nth-child(2) {
        border-top: 1px solid #ececec;
    }

    .help-visual {
        flex-basis: 120px;
    }

    .viewer-help-start {
        width: 100%;
    }
}

@media (max-width: 460px) {

    .help-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .help-visual {
        flex-basis: auto;
    }
}


/* =====================================================
   RESPONSIVE
===================================================== */

@media (
    max-width: 700px
) {

    .info-panel {

        top:
            12px;

        right:
            12px;

        width:
            260px;
    }


    .viewer-controls {

        bottom:
            10px;

        max-width:
            calc(
                100vw - 20px
            );

        overflow-x:
            auto;
    }


    .viewer-controls button span {

        display:
            none;
    }


    .viewer-controls button {

        padding:
            8px;
    }


    .hotspot-popup {

        width:
            250px;
    }


    .measurement-panel {

        left:
            50%;

        bottom:
            68px;
    }


    .measurement-manager {

        left:
            12px;

        bottom:
            68px;

        width:
            270px;
    }

}

/* =====================================================
   ELEMENTOS INTERACTIVOS: SELECCION LIMPIA
===================================================== */

.viewer-hotspot-label,
.admin-hotspot-label {
    display: none !important;
}

.viewer-point-item.is-selected {
    background: #eeeeee;
    box-shadow: inset 3px 0 0 #111;
}

.viewer-point-item.is-selected .viewer-point-number {
    background: #111;
    color: #fff;
}

.viewer-point-item.is-selected .viewer-point-text strong {
    font-weight: 800;
}

.viewer-point-item.is-selected .viewer-point-state {
    background: #111;
    color: #fff;
}


/* =====================================================
   PREVISUALIZACIÓN DE CAPA PARA HOTSPOTS
===================================================== */

#adminViewer.placing-hotspot,
#adminViewer.placing-hotspot canvas {
    cursor: crosshair !important;
}

#adminViewer.placing-hotspot {
    outline: 2px solid rgba(43, 124, 255, .16);
    outline-offset: -2px;
}
/* =====================================================
   GALERÍA DE RENDERS
===================================================== */

.renders-gallery-open {
    position: fixed;

    top: 22px;
    left: 50%;

    z-index: 300;

    transform:
        translateX(-50%);

    display: flex;
    flex-direction: column;
    align-items: center;

    min-width: 130px;

    padding: 9px 15px;

    border: 1px solid
        rgba(255,255,255,.16);

    border-radius: 10px;

    background:
        rgba(20,20,20,.90);

    color: #fff;

    cursor: pointer;

    box-shadow:
        0 8px 28px
        rgba(0,0,0,.18);

    backdrop-filter:
        blur(12px);

    transition:
        opacity .18s ease,
        transform .18s ease,
        background .18s ease;
}


.renders-gallery-open:hover {
    background:
        rgba(20,20,20,.98);

    transform:
        translateX(-50%)
        translateY(-2px);
}


.renders-gallery-open span {
    font-size: 11px;
    font-weight: 700;
}


.renders-gallery-open small {
    margin-top: 2px;

    color: #aaa;

    font-size: 8px;
}


.renders-gallery-open.is-hidden {
    display: none;
}


/* =====================================================
   MODAL
===================================================== */

.renders-gallery {
    position: fixed;

    inset: 0;

    z-index: 5000;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 24px;

    visibility: hidden;
    opacity: 0;

    pointer-events: none;

    transition:
        opacity .20s ease,
        visibility .20s ease;
}


.renders-gallery.is-visible {
    visibility: visible;

    opacity: 1;

    pointer-events: auto;
}


.renders-gallery-backdrop {
    position: absolute;

    inset: 0;

    background:
        rgba(8,9,11,.78);

    backdrop-filter:
        blur(12px);
}


.renders-gallery-window {
    position: relative;

    z-index: 1;

    width:
        min(
            1200px,
            94vw
        );

    height:
        min(
            850px,
            92vh
        );

    display: flex;
    flex-direction: column;

    overflow: hidden;

    border:
        1px solid
        rgba(255,255,255,.10);

    border-radius: 18px;

    background:
        #111;

    box-shadow:
        0 30px 100px
        rgba(0,0,0,.45);

    transform:
        translateY(15px)
        scale(.98);

    transition:
        transform .20s ease;
}


.renders-gallery.is-visible
.renders-gallery-window {
    transform:
        translateY(0)
        scale(1);
}


/* =====================================================
   HEADER
===================================================== */

.renders-gallery-header {
    display: flex;

    align-items: center;
    justify-content: space-between;

    gap: 20px;

    padding:
        16px 20px;

    border-bottom:
        1px solid
        rgba(255,255,255,.08);
}


.renders-gallery-header small {
    display: block;

    margin-bottom: 3px;

    color: #777;

    font-size: 8px;

    font-weight: 800;

    letter-spacing: .16em;
}


.renders-gallery-header strong {
    color: #fff;

    font-size: 14px;
}


.renders-gallery-close {
    width: 32px;
    height: 32px;

    flex-shrink: 0;

    border: 0;

    border-radius: 50%;

    background:
        rgba(255,255,255,.08);

    color: #fff;

    font-size: 20px;

    cursor: pointer;
}


.renders-gallery-close:hover {
    background:
        rgba(255,255,255,.16);
}


/* =====================================================
   IMAGEN PRINCIPAL
===================================================== */

.renders-gallery-main {
    position: relative;

    flex: 1 1 auto;

    width: 100% !important;
    min-width: 0 !important;
    min-height: 0 !important;

    display: flex !important;
    align-items: center;
    justify-content: center;

    padding: 18px 70px;

    overflow: hidden;

    box-sizing: border-box;
}


.renders-gallery-image-wrap {
    position: relative;

    width: 100%;
    height: 100%;

    display: flex;

    align-items: center;
    justify-content: center;
}


.renders-gallery-image-wrap img {
    max-width: 100%;
    max-height: 100%;

    display: block;

    object-fit: contain;

    border-radius: 5px;

    box-shadow:
        0 12px 40px
        rgba(0,0,0,.25);
}


.renders-gallery-loading {
    position: absolute;

    color: #888;

    font-size: 11px;

    pointer-events: none;
}


/* =====================================================
   FLECHAS
===================================================== */

.renders-gallery-nav {
    position: absolute;

    top: 50%;

    z-index: 2;

    transform:
        translateY(-50%);

    width: 42px;
    height: 42px;

    border:
        1px solid
        rgba(255,255,255,.10);

    border-radius: 50%;

    background:
        rgba(255,255,255,.08);

    color: #fff;

    font-size: 27px;

    line-height: 1;

    cursor: pointer;

    transition:
        background .15s ease,
        transform .15s ease;
}


.renders-gallery-nav:hover {
    background:
        rgba(255,255,255,.16);
}


.renders-gallery-prev {
    left: 12px;
}


.renders-gallery-next {
    right: 12px;
}


/* =====================================================
   FOOTER
===================================================== */

.renders-gallery-footer {
    display: grid;

    grid-template-columns:
        1fr
        auto
        auto;

    align-items: center;

    gap: 18px;

    padding:
        12px 18px;

    border-top:
        1px solid
        rgba(255,255,255,.08);

    background:
        #111;
}


.renders-gallery-title {
    min-width: 0;

    overflow: hidden;

    color: #fff;

    font-size: 11px;

    font-weight: 700;

    text-overflow: ellipsis;

    white-space: nowrap;
}


.renders-gallery-counter {
    color: #777;

    font-size: 10px;
}


.renders-gallery-actions {
    display: flex;

    gap: 6px;
}


.renders-gallery-actions button {
    min-height: 31px;

    padding:
        0 11px;

    border:
        1px solid
        rgba(255,255,255,.10);

    border-radius: 7px;

    background:
        rgba(255,255,255,.06);

    color: #fff;

    cursor: pointer;

    font: inherit;

    font-size: 9px;

    font-weight: 600;
}


.renders-gallery-actions button:hover {
    background:
        rgba(255,255,255,.13);
}


/* =====================================================
   MINIATURAS
===================================================== */

.renders-gallery-thumbs {
    display: flex;

    gap: 7px;

    min-height: 72px;

    padding:
        8px 12px;

    overflow-x: auto;

    background:
        #111;
}


.renders-gallery-thumb {
    width: 82px;
    height: 52px;

    flex:
        0 0 82px;

    padding: 0;

    overflow: hidden;

    border:
        2px solid
        transparent;

    border-radius: 6px;

    background:
        #222;

    cursor: pointer;

    opacity: .55;

    transition:
        opacity .15s ease,
        border-color .15s ease;
}


.renders-gallery-thumb:hover {
    opacity: .85;
}


.renders-gallery-thumb.is-active {
    border-color: #fff;

    opacity: 1;
}


.renders-gallery-thumb img {
    width: 100%;
    height: 100%;

    display: block;

    object-fit: cover;
}


body.renders-gallery-opened {
    overflow: hidden;
}


/* =====================================================
   RESPONSIVE
===================================================== */

@media (
    max-width: 700px
) {

    .renders-gallery-open {
        top: 12px;
    }


    .renders-gallery {
        padding: 10px;
    }


    .renders-gallery-window {
        width: 100%;
        height: 94vh;

        border-radius: 13px;
    }


    .renders-gallery-main {
        padding:
            15px 45px;
    }


    .renders-gallery-footer {
        grid-template-columns:
            1fr auto;

        gap: 8px;
    }


    .renders-gallery-counter {
        display: none;
    }


    .renders-gallery-actions {
        grid-column: 1 / -1;
    }


    .renders-gallery-actions button {
        flex: 1;
    }


    .renders-gallery-nav {
        width: 34px;
        height: 34px;
    }


    .renders-gallery-prev {
        left: 7px;
    }


    .renders-gallery-next {
        right: 7px;
    }

}
/* =====================================================
   GALERÍA PÚBLICA DE RENDERS
===================================================== */

body.renders-gallery-open {
    overflow: hidden;
}

#rendersGalleryButton {
    order: 20;
}

.renders-gallery {
    position: fixed;
    inset: 0;
    z-index: 2000;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 24px;

    opacity: 0;
    visibility: hidden;
    pointer-events: none;

    transition:
        opacity .2s ease,
        visibility .2s ease;
}

.renders-gallery.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.renders-gallery-backdrop {
    position: absolute;
    inset: 0;

    background:
        rgba(10, 10, 10, .68);

    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.renders-gallery-dialog {
    position: relative;
    z-index: 1;

    width: min(1180px, 100%);
    height: min(88vh, 820px);

    display: flex;
    flex-direction: column;

    overflow: hidden;

    border-radius: 18px;

    background:
        rgba(255, 255, 255, .98);

    box-shadow:
        0 30px 100px
        rgba(0, 0, 0, .32);

    transform:
        translateY(14px)
        scale(.98);

    transition:
        transform .2s ease;
}

.renders-gallery.is-open
.renders-gallery-dialog {
    transform:
        translateY(0)
        scale(1);
}

.renders-gallery-close {
    position: absolute;

    top: 15px;
    right: 15px;

    z-index: 5;

    width: 34px;
    height: 34px;

    border: 0;
    border-radius: 50%;

    background: #eeeeee;

    color: #444;

    font-size: 22px;
    line-height: 34px;

    cursor: pointer;
}

.renders-gallery-close:hover {
    background: #e2e2e2;
}

.renders-gallery-header {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 20px;

    padding:
        22px 58px 17px 24px;

    border-bottom:
        1px solid #eeeeee;
}

.renders-gallery-header small {
    display: block;

    margin-bottom: 4px;

    font-size: 8px;
    font-weight: 800;
    letter-spacing: .14em;

    color: #888;
}

.renders-gallery-header h2 {
    margin: 0;

    font-size: 20px;
    line-height: 1.1;

    color: #111;
}

.renders-gallery-counter {
    font-size: 10px;
    font-weight: 700;

    color: #777;
}

.renders-gallery-main {
    min-height: 0;
    flex: 1;

    display: grid;
    grid-template-columns: 52px minmax(0, 1fr) 52px;

    align-items: center;

    gap: 12px;

    padding: 18px;
}

.renders-gallery-image-wrap {
    position: relative;

    width: 100% !important;
    height: 100% !important;

    min-width: 0 !important;
    min-height: 0 !important;

    display: flex !important;
    align-items: center !important;
    justify-content: center !important;

    overflow: hidden;

    border-radius: 12px;

    background: #f3f3f3;
}

.renders-gallery-image {
    position: absolute !important;

    inset: 0 !important;

    display: block !important;

    width: 100% !important;
    height: 100% !important;

    max-width: none !important;
    max-height: none !important;

    margin: 0 !important;
    padding: 0 !important;

    object-fit: contain !important;
    object-position: center !important;
}

.renders-gallery-nav {
    width: 42px;
    height: 42px;

    padding: 0;

    border: 0;
    border-radius: 50%;

    background: #111;

    color: #fff;

    font-size: 28px;
    line-height: 42px;

    cursor: pointer;

    transition:
        opacity .15s ease,
        transform .15s ease;
}

.renders-gallery-nav:hover {
    transform: scale(1.05);
}

.renders-gallery-nav:disabled {
    opacity: .25;
    cursor: default;
    transform: none;
}

.renders-gallery-footer {
    display: flex;
    align-items: center;

    gap: 15px;

    padding:
        12px 18px 18px;

    border-top:
        1px solid #eeeeee;
}

.renders-gallery-thumbs {
    min-width: 0;
    flex: 1;

    display: flex;
    align-items: center;

    gap: 7px;

    overflow-x: auto;

    scrollbar-width: thin;
}

.renders-gallery-thumb {
    width: 78px;
    height: 54px;

    flex: 0 0 78px;

    padding: 2px;

    border:
        1px solid #dddddd;

    border-radius: 7px;

    background: #fff;

    cursor: pointer;

    overflow: hidden;

    opacity: .72;

    transition:
        opacity .15s ease,
        border-color .15s ease;
}

.renders-gallery-thumb:hover,
.renders-gallery-thumb.is-active {
    opacity: 1;
    border-color: #111;
}

.renders-gallery-thumb img {
    width: 100%;
    height: 100%;

    display: block;

    object-fit: cover;

    border-radius: 4px;
}

.renders-gallery-download {
    flex: 0 0 auto;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 34px;

    padding:
        0 13px;

    border-radius: 8px;

    background: #111;

    color: #fff;

    text-decoration: none;

    font-size: 9px;
    font-weight: 700;

    white-space: nowrap;
}

.renders-gallery-download:hover {
    background: #2b2b2b;
}

@media (max-width: 700px) {

    .renders-gallery {
        padding: 10px;
    }

    .renders-gallery-dialog {
        height: calc(100vh - 20px);
        border-radius: 14px;
    }

    .renders-gallery-header {
        padding:
            18px 52px 14px 17px;
    }

    .renders-gallery-header h2 {
        font-size: 17px;
    }

    .renders-gallery-main {
        grid-template-columns:
            38px minmax(0, 1fr) 38px;

        gap: 6px;

        padding: 10px;
    }

    .renders-gallery-nav {
        width: 34px;
        height: 34px;

        font-size: 23px;
        line-height: 34px;
    }

    .renders-gallery-footer {
        align-items: stretch;
        flex-direction: column;

        padding:
            9px 10px 12px;
    }

    .renders-gallery-thumb {
        width: 68px;
        height: 48px;

        flex-basis: 68px;
    }

    .renders-gallery-download {
        width: 100%;
    }
}
.renders-gallery-actions {
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 0 0 auto;
}

.renders-gallery-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 110px;
    height: 30px;

    padding: 0 13px;

    border: 0;
    border-radius: 7px;

    font-family: inherit;
    font-size: 9px;
    font-weight: 700;

    text-decoration: none !important;

    box-sizing: border-box;
    cursor: pointer;
}

.renders-gallery-open-image {
    background: #111 !important;
    color: #fff !important;
}

.renders-gallery-open-image:hover {
    background: #292929 !important;
    color: #fff !important;
}

.renders-gallery-download-file {
    background: #eeeeee !important;
    color: #222 !important;
}

.renders-gallery-download-file:hover {
    background: #dddddd !important;
    color: #111 !important;
}