/* BOTON INFORMACION IMPORTANTE */
.boton-popup {
    position: fixed !important;
    top: 140px !important;
    left: 500px !important;
    z-index: 2147483647 !important;
    display: none !important;
}

.boton-popup.ayuda-visible {
    display: inline-flex !important;
}

@keyframes senalarDedo {
    50% {
        transform: translateX(8px) translateY(5px) rotate(-15deg);
    }
}

.popup-overlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    display: none !important;
    pointer-events: none !important;
    z-index: 2147483647 !important;
}

.popup-contenido {
    position: absolute;
    top: 180px;
    left: 50%;
    transform: translateX(-50%);
    will-change: left, top;
    width: 420px;
    max-width: 90%;
    background: #FFFFFF;
    border-radius: 10px;
    box-sizing: border-box;
    font-family: Arial, sans-serif;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    pointer-events: auto;
    overflow: hidden;
}

.popup-barra-titulo {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 42px;
    padding: 0 8px 0 16px;
    background: #8A1428;
    color: #FFFFFF;
    cursor: move;
    user-select: none;
    touch-action: none;
}

.popup-contenido h2 {
    margin-top: 0;
    margin-bottom: 0;
    color: #FFFFFF;
    font-size: 16px;
    font-weight: 600;
}

.popup-cuerpo {
    padding: 24px 30px 30px;
    text-align: center;
}

.categoria-detectada {
    margin-bottom: 15px;
    padding: 8px 12px;
    background: #f5f5f5;
    border-radius: 6px;
    color: #666666;
    font-size: 13px;
}

.popup-contenido p {
    margin: 0;
    color: #444444;
    font-size: 16px;
    line-height: 1.5;
}

.popup-cerrar {
    width: 35px;
    height: 35px;
    border: none;
    background: transparent;
    color: #FFFFFF;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
}

.popup-cerrar:hover {
    background: rgba(255, 255, 255, 0.18);
}

.popup-boton {
    margin-top: 25px;
    padding: 10px 25px;
    border: none;
    border-radius: 6px;
    background: #8A1428;
    color: #FFFFFF;
    cursor: pointer;
    font-size: 15px;
}

.popup-boton:hover {
    opacity: 0.9;
}

#contenido-ayuda {
    max-height: min(62vh, 560px);
    overflow-y: auto;
    overflow-anchor: none;
    scroll-behavior: auto;
    padding-right: 6px;
    text-align: left;
}

#contenido-ayuda::-webkit-scrollbar {
    width: 8px;
}

#contenido-ayuda::-webkit-scrollbar-thumb {
    background: #c8cbd0;
    border-radius: 8px;
}

.plantilla-ayuda {
    color: #34373c;
    font-size: 14px;
    line-height: 1.55;
}

.help-header {
    margin-bottom: 18px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e5e7eb;
}

.help-label {
    display: inline-block;
    margin-bottom: 8px;
    padding: 4px 9px;
    border-radius: 12px;
    background: #fbecef;
    color: #8a1428;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.plantilla-ayuda h3,
.plantilla-ayuda h4 {
    margin: 0;
    color: #272a2f;
}

.plantilla-ayuda h3 {
    font-size: 19px;
    line-height: 1.25;
}

.plantilla-ayuda h4 {
    margin-bottom: 9px;
    font-size: 15px;
}

.help-header p,
.help-section p,
.help-footer {
    margin: 9px 0 0;
}

.help-header p {
    color: #68707b;
}

.help-section {
    margin-bottom: 18px;
}

.help-panel {
    padding: 15px 16px;
    border-left: 3px solid #d99aa8;
    background: #fff9fa;
}

.help-panel-compact {
    padding: 0;
}

.help-panel-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 14px 16px;
}

.help-section-label {
    display: block;
    margin-bottom: 4px;
    color: #8a1428;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.help-panel-summary h4 { margin-bottom: 3px; }
.help-panel-summary p { margin: 0; color: #68707b; font-size: 12px; }

.help-action,
.help-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 32px;
    padding: 7px 11px;
    border: 1px solid #8a1428;
    border-radius: 4px;
    background: #8a1428;
    color: #fff !important;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.2;
    text-decoration: none;
    white-space: nowrap;
    cursor: pointer;
}

.help-action:hover,
.help-toggle:hover { background: #6f0f20; border-color: #6f0f20; }

.help-panel-content { padding: 0 16px 15px; border-top: 1px solid #f0d9de; }
.help-panel-content[hidden] { display: none; }

.help-list {
    display: grid;
    gap: 11px;
    margin: 0;
    padding-left: 22px;
}

.help-list li {
    padding-left: 3px;
}

.plantilla-ayuda a {
    color: #8a1428;
    font-weight: 600;
}

.help-link {
    display: inline-flex;
    margin: 6px 0 0 5px;
}

.help-footer {
    padding-top: 14px;
    border-top: 1px solid #e5e7eb;
    color: #68707b;
    font-size: 12px;
}

.help-section-heading,
.help-section-header {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.help-section-header {
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.help-section-header > div {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.help-section-heading p,
.help-section-header p,
.help-download p {
    margin-top: 6px;
    color: #68707b;
    font-size: 12px;
}

.help-section-number {
    display: inline-flex;
    flex: 0 0 28px;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #fbecef;
    color: #8a1428;
    font-size: 11px;
    font-weight: 700;
}

.help-note {
    margin: 13px 0 0 38px !important;
    color: #68707b;
    font-size: 12px;
}

.help-note a,
.help-footer a {
    color: #8a1428;
    font-weight: 600;
}

.help-items {
    display: grid;
    gap: 8px;
    margin-top: 12px;
}

.help-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px;
    border: 1px solid #e5e7eb;
    border-radius: 5px;
    background: #fff;
}

.help-item strong {
    color: #444950;
    font-size: 13px;
}

.help-action-compact {
    min-height: 28px;
    padding: 6px 10px;
    font-size: 11px;
}

.help-download {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 15px 16px;
}

.help-download,
.help-panel {
    border-left: 3px solid #d99aa8;
    background: #fff9fa;
}

.help-download .help-action {
    flex: 0 0 auto;
}

.help-footer {
    padding-top: 14px;
    border-top: 1px solid #e5e7eb;
    color: #68707b;
    font-size: 12px;
}

@media (max-width: 480px) {
    .help-download,
    .help-section-header {
        align-items: flex-start;
        flex-direction: column;
    }
}

.dedo-indicador {
    position: fixed;
    top: 170px;
    left: 538px;
    z-index: 2147483646;
    display: none;
    width: 48px;
    height: 48px;
    pointer-events: none;
    transform-origin: 50% 100%;
    filter: drop-shadow(0 3px 3px rgba(0, 0, 0, 0.55)) drop-shadow(0 5px 7px rgba(0, 0, 0, 0.30));
}

.dedo-indicador.mostrar {
    display: block;
    animation: dedo-senalar 0.65s ease-in-out infinite;
}

@keyframes dedo-senalar {
    0%, 100% {
        transform: translateX(0) translateY(0) rotate(-8deg);
    }
    50% {
        transform: translateX(7px) translateY(3px) rotate(-8deg);
    }
}

.icono-mano {
    display: block;
    font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif;
    font-size: 42px;
    line-height: 48px;
    text-shadow: 1px 1px 0 #7d2417, -1px -1px 0 #7d2417, 2px 2px 4px rgba(0, 0, 0, 0.55);
}

#ayuda-container,
#ventana-emergente-container,
#prueba-container {
    position: fixed;
    inset: 0;
    z-index: 2147483647;
    pointer-events: none;
}

#ayuda-container > *,
#ventana-emergente-container > *,
#prueba-container > * {
    pointer-events: auto;
}

#popup-prueba-directa {
    position: fixed !important;
    inset: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100vw !important;
    height: 100vh !important;
    background: rgba(0, 0, 0, 0.65) !important;
    z-index: 2147483647 !important;
    pointer-events: auto;
}

#popup-prueba-directa .popup-prueba-contenido {
    position: relative;
    width: 420px;
    max-width: 90%;
    padding: 30px;
    box-sizing: border-box;
    background: #fff;
    border-radius: 10px;
    text-align: center;
    font-family: Arial, sans-serif;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

#popup-prueba-directa h2 { color: #8a1428; }
#popup-prueba-directa p { color: #444; line-height: 1.5; }
#popup-prueba-directa button {
    padding: 10px 25px;
    border: 0;
    border-radius: 6px;
    background: #8a1428;
    color: #fff;
    cursor: pointer;
}
