body {
    font-family: Arial, sans-serif;
    margin: 0;
    background: #f8fafb;
}
.toolbar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 5px;
    background: none;
    
}
.main-area {
    display: flex;
    gap: 24px;
    justify-content: flex-start;
    align-items: stretch;
    margin: 20px 0 0 20px;
    /* height: auto; */ 
    /* width: auto; */
    overflow-x: auto;
    /* Para que main-area crezca según el contenido, no definas height ni min-height aquí. */
    /* Si quieres que ocupe todo el alto de la ventana (menos la toolbar de 56px): */
    /* height: calc(100vh - 56px); */
    /* min-height: 0; */
}

.main-area.vertical-preview-mode {
    /* No min-height ni height: se adapta 100% al contenido en vertical. */
    height: auto !important;
    min-height: 0 !important;
}



.matrix-area {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 400px; /* vertical por defecto */
}
.matrix-area.horizontal {
    width: auto;
    min-width: 520px;
    max-width: 100vw;
}
.matrix-rotated {
    transform: rotate(90deg) translateY(-400px);
    transform-origin: top left;
}
.matrix-controls {
    margin-bottom: 8px;
}
.matrix-con.toolbar {
    margin-bottom: 20px;
    display: flex;
    gap: 8px;
    align-items: center;
}
.tool-btn {
    width: 32px;
    height: 32px;
    padding: 4px;
    border: 1px solid #ccc;
    background: white;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
}
.tool-btn:hover {
    background: #f5f37c;
    border-color: #030303;
    color: #333;
}
.tool-btn.selected {
    background: #1df039;
    border-color: #ff9800;
    color: #fff;
}
.tool-btn svg {
    width: 20px;
    height: 20px;
}
#pixelMatrix {
    display: grid;
    grid-template-columns: repeat(128, 1fr);
    border: 1px solid #b0c4de;
    background: #fff;
    box-shadow: 0 1px 2px #e0e0e0;
    user-select: none;
}
.pixel {
    width: 4px;
    height: 4px;
    border: 1px solid #e3e3e3;
    background: #fafbfc;
    cursor: pointer;
    transition: background 0.1s;
    box-sizing: border-box;
}
.pixel.zone-highlight {
    background: #c6f7c6 !important; /* Verde claro, más visible */
    border-color: #8fd98f !important;
    opacity: 0.75;
}
.pixel.active {
    background: #111 !important;
    border-color: #b0b0ff !important;
    z-index: 2;
    position: relative;
}
.pixel:hover {
    outline: 1px solid #6ab0ff44;
}
.preview-area {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    justify-content: center;
    min-width: 140px;
    /* min-height: 180px;  Eliminado para máxima adaptabilidad */
    gap: 18px;
}
.preview-area.vertical-preview-mode {
    min-height: 0 !important;
    height: auto !important;
}
.oled-preview-frame {
    border: 4px solid #0066ff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    margin: 0 auto;
    background: transparent;
    overflow: visible;
    box-sizing: border-box;
    transition: width 0.2s, height 0.2s;
    /* width: auto; */
    /* height: auto; */
    border-radius: 4px;
}
.oled-preview-frame.vertical-rotate {
    /* Sin rotación: solo sirve para aplicar estilos específicos si necesitas, pero no debe rotar */
    display: flex;
    align-items: center;
    justify-content: center;


    border: 4px solid #0066ff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    margin: 0 auto;
    background: transparent;
    overflow: visible;
    box-sizing: border-box;
    transition: width 0.2s, height 0.2s;
    /* width: auto; */
    /* height: auto; */
}


.oled-preview {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
}



.oled-preview canvas {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    display: block;
    box-sizing: border-box;
    object-fit: contain;
    background: #eee;


    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    display: block;
    box-sizing: border-box;
}
.oled-preview canvas {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    display: block;
    box-sizing: border-box;
    object-fit: contain;
}
.oled-preview canvas {
    width: 100%;
    height: 100%;
    object-fit: unset;
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    display: block;

    background: #eee;




    transform: rotate(90deg);
    margin: 0;
}
.vertical-preview-frame .oled-preview {
    display: flex;
    align-items: center;
    justify-content: center;
}

.vertical-preview-frame .oled-preview {
    display: flex;
    align-items: center;
    justify-content: center;
}


/* --- Ventana flotante Importar Imagen: borde y cabecera naranja --- */
#importImageWindow {
    background: #fff8ed !important;
    border: 2px solid #ff9800 !important;
    border-radius: 12px !important;
    box-shadow: 0 4px 18px 0 rgba(0,0,0,0.13) !important;
    overflow: hidden !important;
}
#importImageWindowHeader {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 15px;
    
    background-color: #f0f0f0;
    border-bottom: 1px solid #ccc;
    font-weight: bold;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}

.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0 0 5px rgba(33, 150, 243, 0.4) !important;
}
.oled-preview canvas {
    display: block;
    margin: 0;
    padding: 0;
}
.oled-preview {
    display: block;
}
.preview-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    margin-right: 0px;
    margin-top: 0;
    height: 100%;
    min-width: 0;
    width: 30px;
    box-sizing: border-box;
}
.hex-output {
    margin: 20px;
    width: 600px;
}
#zoomPreview {
    transform: rotate(-90deg);
    width: 70px;
    height: 24px;
    margin: 60px 0 8px 0;
    display: block;
}
#zoomPreviewVal {
    display: block;
    margin-top: 24px;
    text-align: center;
    font-size: 14px;
    transform: none;
    /* width: auto; */
    height: 100%;
}
#hexOutput {
    width: 70%;
    height: 400px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px;
    resize: none;
    background: #f5f7fa;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    display: block;
}
.vertical-matrix {
    transform: rotate(90deg);
    transform-origin: top left;
    margin-left: 64px;
}
.vertical-preview {
    transform: rotate(90deg);
    transform-origin: center;
    margin-left: 0;
}
.selected {
    background-color: #e6f0ff !important;
    color: #2196f3 !important;
    border: 3px solid #2196f3 !important;
    box-shadow: 0 0 3px rgba(33, 150, 243, 0.3) !important;
    transform: scale(1.02) !important;
    transition: all 0.2s ease !important;
}

.selected:hover {
    background-color: #f0f7ff !important;
    border-color: #1976d2 !important;
    box-shadow: 0
}
/* No se necesita clase específica si horizontal es el estado por defecto */
/* O si necesitas ajustes específicos para horizontal: */
.matrix-horizontal {
    transform: rotate(0deg) translateY(0px);
    transform-origin: top left;
}