@import url('https://fonts.googleapis.com/css2?family=Noto+Nastaliq+Urdu&family=Amiri&family=Scheherazade+New&family=Lateef&display=swap');


        body {
            font-family: Amiri, sans-serif; 
            margin: 0;
            padding: 20px;
            background-color: #f5f5f5;
        }

        .contenedor-input {
           /* margin-bottom: 20px; */
            width: 95%;
            margin: 0 auto;
        }

        .contador-caracteres {
            text-align: left;
            margin-top: 5px;
            color: #666;
        }
        
	.fila-teclas {
            display: flex;
            flex-wrap: wrap;
            justify-content: center;
            margin-bottom: 8px;
            gap: 5px;
        }
  

      	.btn-control {
            padding: 0 4px;
            font-size: 16px;
            border: 1px solid #ccc;
            border-radius: 5px;
            cursor: pointer;
            min-width: 35px;
        }

     	.btn-control2 {
            padding: 0 4px;
            font-size: 16px;
            border: 1px solid #ccc;
            border-radius: 5px;
            cursor: pointer;
            min-width: 35px;
        }

	.btn-control22 {
	    padding: 0 4px;
            font-size: 16px;
            border: 1px solid #ccc;
            border-radius: 5px;
            cursor: pointer;
            min-width: 35px;

	    background-color: #8A2BE2 !important;
	    color: white !important;
	}

     	.btn-control1 {
            padding: 0 4px;
            font-size: 16px;
            border: 1px solid #ccc;
            border-radius: 5px;
            cursor: pointer;
            min-width: 35px;
            /*color: #8a2be2;    */
       	}


	.tecla {
	    /* min-width: 40px; 
	    height: 40px; 
	    margin: 1px; 
	    border: 1px solid #ccc; 
            border-bottom: 3px solid #1a1a1a; 
	    border-radius: 4px;
	    cursor: pointer; 
	    display: flex; 
	    align-items: center;
	    justify-content: center;
	    font-size: 18px; 
	    user-select: none;
	    padding: 0 4px;
	    font-family: 'Amiri', 'Scheherazade New', 'Lateef', serif; 
	    transition: all 0.2s ease; */
            display: flex;
            align-items: center;
            justify-content: center;
            width: 40px;
            height: 40px;
	    background: #f8f9fa; 
            border: 1px solid #2a2a2a;
            border-bottom: 3px solid #1a1a1a;
            /*color: white;*/
            /*text-shadow: 0 -1px 0 #000; */
            box-shadow: 0 3px 5px rgba(0,0,0,0.3);
            font-family: 'Amiri', 'Scheherazade New', 'Lateef', serif; /* font-family: lateef, serif; */
            font-size: 18px;
            cursor: pointer;
            transition: all 0.1s ease;
            flex-shrink: 0;

	}

    .tecla-oscura {
            display: flex;
            align-items: center;
            justify-content: center;
            width: 40px;
            height: 40px;
            background: linear-gradient(145deg, #4a4a4a, #3a3a3a);
            border: 1px solid #2a2a2a;
            border-bottom: 3px solid #1a1a1a;
            color: white;
            text-shadow: 0 -1px 0 #000;
            box-shadow: 0 3px 5px rgba(0,0,0,0.3);
            font-family: 'Amiri', 'Scheherazade New', 'Lateef', serif; /* font-family: lateef, serif; */
            font-size: 18px;
            cursor: pointer;
            transition: all 0.1s ease;
            flex-shrink: 0;
        }

        .tecla:hover {
            background: #e9ecef;
            transform: translateY(-1px);
        }

        .btn-control {
           /* background-color: red; /*#e0e0e0;*/	
        }
        .tecla:hover, .btn-control:hover {
            background-color: #d0d0d0;
        }
        .tecla-numero {
            color: #7b1fa2;
            background-color: #f0f0f0;
        }
        .tecla-May {
            background-color: #e8f4fd;
        } 
        .tecla-Alt {
            color: #bf3c2c;
            background-color: #e8f4fd;
        }
        .tecla-AltGr {
            color: #bf3c2c;
            background-color: #e8f4fd;
        }

	.tecla-e {
	    color: #f0ffff;      
	    background: #8a2be2; 
	}

	.tecla-e:hover {
	    background: #e1bee7;
	}

	.tecla-e1{
	    color: #8a2be2;      
	}

	.tecla-e2{
            color: #8a2be2;      

        }


	.tecla-ma {
	    background: #dc143c; /* #f3e5f5; */
	    color: #f0ffff; /*#7b1fa2; */
	}

	.tecla-ma:hover {
	    background: #e1bee7;
	}

	.tecla-persa {
    	    font-family: 'Noto Nastaliq Urdu', serif; 
	    font-size: 15px; 
	    background: #f3e5f5;
	    color: #7b1fa2;
	}

	.tecla-persa:hover {
	    background: #e1bee7;
	}

	.tecla-at {
	    background: #5db26c; /* #183f20; #f3e5f5; */
	    color: #f0ffff; /*#7b1fa2; */
	}

	.tecla-at:hover {
	    background: #e1bee7;
	}

	.tecla-Ctrl {
	    font-size: 15px;
	}

	.tecla-CtrlGr {
	    font-size: 15px;
	}

	center {
            margin: 20px 0;
            font-size: 20px;
            font-weight: bold;
        }

        .modo-espanol {
            direction: ltr;
            text-align: left;
        }

       .teclado {
            display: inline-block;
            background: #2a2a2a;
            padding: 15px;
            border-radius: 10px;
            box-shadow: 0 10px 20px rgba(0,0,0,0.3);
        }

        .fila-teclas {
            display: flex;
            justify-content: center;
            margin-bottom: 8px;
            gap: 4px;
        }

       .tecla-oscura:active {
            transform: translateY(2px);
            border-bottom-width: 1px;
            background: linear-gradient(145deg, #3a3a3a, #2a2a2a);
        }

        /* Teclas especiales con diferentes anchos */
	.tecla-media {
            width: 70px;
	}
        .tecla-grande {
            width: 80px;
        }

        .tecla-extra-grande {
            width: 120px;
        }

        .tecla-doble-ancho {
            width: 100px;
        }

        .tecla-triple-ancho {
            width: 150px;
        }

        .tecla-espacio {
            width: 333px;
        }

        .contenedor-input {
            margin-bottom: 20px;
        }

      .input-arabe {
            padding: 10px;
            border: 2px solid #4a4a4a;
            border-radius: 5px;
            /*background: #1a1a1a;
            color: white;*/
            font-family: Amiri, serif;
            width: 100%;
            font-size: 22px;
            direction: rtl;
            text-align: right;
        }

    .input-latin {
            padding: 10px;
            border: 2px solid #4a4a4a;
            border-radius: 5px;
            /*background: #1a1a1a;
            color: white;*/
            font-family: Amiri, serif;
            width: 100%;
            font-size: 22px;
            direction: ltr;
            text-align: left;
        }

        /* Estilos para notificaciones */
        .notificacion {
            position: fixed;
            top: 20px;
            right: 20px;
            padding: 10px 20px;
            border-radius: 5px;
            color: white;
            z-index: 1000;
            font-weight: bold;
        }

        .notificacion.exito {
            background-color: #4CAF50;
        }

        .notificacion.error {
            background-color: #f44336;
        }

        .notificacion.info {
            background-color: #2196F3;
        }


/* Estilos para el textarea y selector de fuentes */
#input-arabe {
    font-family: inherit; /* Heredará la fuente aplicada por JavaScript */
    font-size: 20px; /* Tamaño base adecuado */
    transition: font-family 0.3s ease; /* Transición suave al cambiar fuente */
}

/* Estilos para el selector */
select {
    font-family: Arial, sans-serif; /* Fuente legible para el selector */
    padding: 5px;
    border: 1px solid #ccc;
    border-radius: 4px;
    background-color: white;
}

/* nuevo teclado */ 

/* Estilos para vistas de teclado */
.tecla {
    transition: all 0.2s ease;
}

/* Contador de caracteres */
.contador-caracteres {
    text-align: right;
    font-size: 12px;
    color: #666;
    margin-top: 5px;
    padding: 2px 10px;
    background: #f8f9fa;
    border-radius: 3px;
    transition: all 0.3s ease;
}

.contador-caracteres.advertencia-limite {
    color: #ffc107;
    font-weight: bold;
    background: #fff8e1;
}

.contador-caracteres.cerca-limite {
    color: #ff9800;
    font-weight: bold;
    background: #fff3e0;
}

.contador-caracteres.limite-excedido {
    color: #f44336;
    font-weight: bold;
    background: #ffebee;
}

/* Botones activos - ESTILOS MEJORADOS PARA IZQUIERDA/DERECHA */
.btn-control.activo {
    background: #4CAF50 !important;
    color: white !important;
    box-shadow: 0 0 8px rgba(76, 175, 80, 0.6);
    border: 2px solid #388E3C !important;
}

.btn-control.activo-may {
    background: #4CAF50 !important;
    color: white !important;
    box-shadow: 0 0 8px rgba(76, 175, 80, 0.6);
}

/* Control izquierdo - Azul */
.btn-control.activo-ctrl {
    background: #2196F3 !important;
    color: white !important;
    box-shadow: 0 0 8px rgba(33, 150, 243, 0.6);
}

/* Control derecho - Azul oscuro */
.btn-control.activo-ctrl-der {
    background: #1976D2 !important;
    color: white !important;
    box-shadow: 0 0 8px rgba(25, 118, 210, 0.6);
}

/* Alt izquierdo - Naranja */
.btn-control.activo-alt {
    background: #FF9800 !important;
    color: white !important;
    box-shadow: 0 0 8px rgba(255, 152, 0, 0.6);
}

/* AltGr (Alt derecho) - Naranja oscuro */
.btn-control.activo-altgr {
    background: #F57C00 !important;
    color: white !important;
    box-shadow: 0 0 8px rgba(245, 124, 0, 0.6);
}

/* Estados de teclas especiales */
.tecla.activa-may {
    background: #4CAF50 !important;
    color: white !important;
}

.tecla.activa-ctrl {
    background: #2196F3 !important;
    color: white !important;
}

.tecla.activa-alt {
    background: #FF9800 !important;
    color: white !important;
}

.tecla.activa-altgr {
    background: #F57C00 !important;
    color: white !important;
}

/* Mejoras visuales */
.input-arabe {
    transition: all 0.3s ease;
}

.fila-teclas {
    transition: all 0.3s ease;
}

/* Botón de tecla base específico */
.btn-control[onclick*="teclaBase"].activo {
    background: #4CAF50 !important;
    color: white !important;
    font-weight: bold;
}
